Package ca.uhn.fhir.jpa.migrate
Class JdbcUtils
java.lang.Object
ca.uhn.fhir.jpa.migrate.JdbcUtils
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetColumnNames(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName) Retrieve all index namesstatic JdbcUtils.ColumnTypegetColumnType(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName, String theColumnName) Retrieve all index namesgetForeignKeys(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName, String theForeignTable) Retrieve all index namesgetForeignKeysForColumn(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theForeignKeyColumn, String theForeignTable) Retrieve names of foreign keys that reference a specified foreign key column.getIndexNames(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName) Retrieve all index namesgetSequenceNames(DriverTypeEnum.ConnectionProperties theConnectionProperties) getTableNames(DriverTypeEnum.ConnectionProperties theConnectionProperties) static booleanisColumnNullable(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName, String theColumnName) static booleanisIndexUnique(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName, String theIndexName)
-
Constructor Details
-
JdbcUtils
public JdbcUtils()
-
-
Method Details
-
getIndexNames
public static Set<String> getIndexNames(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName) throws SQLException Retrieve all index names- Throws:
SQLException
-
isIndexUnique
public static boolean isIndexUnique(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName, String theIndexName) throws SQLException - Throws:
SQLException
-
getColumnType
public static JdbcUtils.ColumnType getColumnType(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName, String theColumnName) throws SQLException Retrieve all index names- Throws:
SQLException
-
getForeignKeys
public static Set<String> getForeignKeys(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName, @Nullable String theForeignTable) throws SQLException Retrieve all index names- Throws:
SQLException
-
getForeignKeysForColumn
public static Set<String> getForeignKeysForColumn(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theForeignKeyColumn, String theForeignTable) throws SQLException Retrieve names of foreign keys that reference a specified foreign key column.- Throws:
SQLException
-
getColumnNames
public static Set<String> getColumnNames(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName) throws SQLException Retrieve all index names- Throws:
SQLException
-
getSequenceNames
public static Set<String> getSequenceNames(DriverTypeEnum.ConnectionProperties theConnectionProperties) throws SQLException - Throws:
SQLException
-
getTableNames
public static Set<String> getTableNames(DriverTypeEnum.ConnectionProperties theConnectionProperties) throws SQLException - Throws:
SQLException
-
isColumnNullable
public static boolean isColumnNullable(DriverTypeEnum.ConnectionProperties theConnectionProperties, String theTableName, String theColumnName) throws SQLException - Throws:
SQLException
-