Using JDBC to connect to Cache Database URL

Caché, JDBC

I'm referring to the document Using Cache with JDBC. Using this example, it sets the URL of the object ds of class CacheDataSource.


My question is would you just copy and paste the URL from the login page to the string? I tried doing that and it returns an error saying "Invalid log file xyz"


Any help will be greatly appreciated! Thank you

  • 0
  • 0
  • 678
  • 2
  • 2


Not clear what you mean with "login page".
for the MgmtPoatal you connect to a HTTP port (default=57772) with a CSP PAGE and and and ...

With JDBC you connect to the object service port (default = 1972)  + namespace  

The IP address is of course the same. Here  or localhost 

Cache JDBC schema is:



What should the argument of is? Is it the directory of where the local database is located at? Let's say my database is under /cache/db/cache.dat and the port is 12345, should the URL be "jdbc:Cache://localhost:12345/cache/db/cache.dat" for the jdbc scheme? Thank you in advance

You are missing the point.

12345 is the port used by the cache DB server   (default=1972) of your instance.
internally there is a mapping between the logical NAMESPACE and the physical disk directory and that NAMESPACE is used in connection string.
if your namespace is called DB then  you have to use 


But if you just have the directory .../cache/db/cache.dat  you can't say what NAMESPACE this is
You have to know your Caché configuration.

Some reading on Caché configuration may give you background information