java – Get the compatible version of Oracle Database using JDBC APIs
java – Get the compatible version of Oracle Database using JDBC APIs
I doubt there is one because the meaning of parameters is highly dependent on particular database engines and would be extremely hard to abstract out. If anything, I could imagine that Oracles oracle.jdbc.OracleDatabaseMetaData class implementing something to query initialization parameters via the oracle.jdbc.AdditionalDatabaseMetaData interface but that wasnt one of the extensions Oracle has chosen to build thus far.
In your example, a 19c database with compatible
set to 12.1.0.2 would support 99% of the new 19c functionality. The only things that wouldnt work would be anything that changed the format of the data files on disk. There tend to be very few such features– the vast majority of new functionality is implemented at a much higher level of the stack. This is fundamentally different than, say, what the compatibility level setting on SQL Server means. It certainly wouldnt make sense for getDatabaseMajorVersion
and getDatabaseProductVersion
to return information based on the setting of the compatible
parameter because that would be misleading for the vast majority of version-specific issues.