how do i get the current schema on DB2 if i have a JDBC conneciton?

后端 未结 2 1883
Happy的楠姐
Happy的楠姐 2020-12-30 05:42

If I have an instance of a JDBC DB2 connection, how do I get the current schema?

Either a SQL statement would work, or just a JDBC method call.

相关标签:
2条回答
  • 2020-12-30 06:14

    Take a look at Java API Makes Database Metadata as Easily Accessible as POJOs for an easy way to obtain schema information.

    0 讨论(0)
  • 2020-12-30 06:23
    select current_schema  
    from   sysibm.sysdummy1
    ;
    
    0 讨论(0)
提交回复
热议问题