0

I'm trying to connect to a database supplied by a vendor. I have read-only access. Every tool I use (SQLWorkbench, DBeaver, etc...) refuses to connect using the jconn4 drivers with an error message along the lines of:

Metadata accessor information was not found on this database. Please install the required tables as mentioned in the jConnect documentation.

Normally the fix is easy. Run:

ALTER DATABASE Upgrade JCONNECT ON

Unfortunately in this instance, I only have read-only access and the vendor refuses to turn it on. Apparently with good reason. I took a snapshot of the Windows server, then did a few tricks in the background to get access to the database with read/write privileges and ran the command. Then I restarted the database server. Every client that uses the database started crashing and throwing bizarre errors. I rolled back to the backup and called the vendor and played dumb. They immediately knew the issue and said "somehow someone turned on metadata accessor tables--good thing you had a backup" and that was the end of it.

Is it possible to access the database without turning on those tables? Are they specifically related to using jconn4 for connecting? Is there another way to connect? (I don't pretend to understand anything about the jconn4 library or Sybase--I rabidly dislike both things). Ideally I would love to be able to browse tables and key relationships with a GUI, but I'd settle for just being able to execute SQL commands and get results while testing.

Aaron C. de Bruyn
  • 2,347
  • 1
  • 30
  • 40
  • 1
    If you check sp_version there will be a default installation of JConnect (installjdbc) listed which has been installed by default with the underlying database software. If you connect with the same JConnect driver version as this you don't need to install any additional metadata as it's there already. This works for Sybase ASE I'm not sure about SQL Anywhere though. – Rich Campbell Oct 19 '20 at 06:33
  • Hmm. It says "Procedure 'sp_version' not found" – Aaron C. de Bruyn Oct 19 '20 at 22:13
  • 1
    I had a quick check on the SAP site and unfortunately I don't see a comparable proc in SQL Anywhere. You should still be able to use dbisql to connect to the database and run queries without any JConnect functionality though albeit without a GUI. – Rich Campbell Oct 20 '20 at 06:23
  • Yeah, I can already do that. It's how I connect with a Python app and pull data I need. It's just easier to run test SQL commands and work on gathering info for reports in a GUI instead of taking a wild stab at it, then pushing the code up, waiting for it to deploy to Kubernetes, then seeing what I broke. ;) – Aaron C. de Bruyn Oct 20 '20 at 18:54

0 Answers0