All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ge.schemacrawler.schemacrawler-sqlserver.10.08.04.source-code.schemacrawler-sqlserver.config.properties Maven / Gradle / Ivy

There is a newer version: 10.10.05
Show newest version
driver=net.sourceforge.jtds.jdbc.Driver
host=localhost
port=1433
url=jdbc:jtds:sqlserver://${host}:${port}/${database};appName=SchemaCrawler;useCursors=true

select.INFORMATION_SCHEMA.ROUTINES=\
SELECT \
  ROUTINE_CATALOG, \
  ROUTINE_SCHEMA, \
  ROUTINE_NAME, \
  SPECIFIC_NAME, \
  ROUTINE_TYPE, \
  ROUTINE_BODY, \
  OBJECT_DEFINITION(OBJECT_ID(ROUTINE_CATALOG + '.' + ROUTINE_SCHEMA + '.' + ROUTINE_NAME)) \
    AS ROUTINE_DEFINITION, \
  * \
FROM \
  INFORMATION_SCHEMA.ROUTINES
  
select.INFORMATION_SCHEMA.VIEWS=\
SELECT \
  TABLE_CATALOG, \
  TABLE_SCHEMA, \
  TABLE_NAME, \
  CHECK_OPTION, \
  IS_UPDATABLE, \
  OBJECT_DEFINITION(OBJECT_ID(TABLE_CATALOG + '.' + TABLE_SCHEMA + '.' + TABLE_NAME)) \
    AS VIEW_DEFINITION \
FROM \
  INFORMATION_SCHEMA.VIEWS
  
select.INFORMATION_SCHEMA.TABLE_CONSTRAINTS=\
  SELECT \
    * \
  FROM \
    INFORMATION_SCHEMA.TABLE_CONSTRAINTS

select.INFORMATION_SCHEMA.CONSTRAINT_COLUMN_USAGE \
SELECT \ 
  *, \
  0 AS ORDINAL_POSTION \
FROM \
  INFORMATION_SCHEMA.CONSTRAINT_COLUMN_USAGE
    
select.INFORMATION_SCHEMA.EXT_TABLE_CONSTRAINTS=\
  SELECT \
    * \
  FROM \
    INFORMATION_SCHEMA.CHECK_CONSTRAINTS
    
select.INFORMATION_SCHEMA.TRIGGERS=\
SELECT \
  information_schema_tables.TABLE_CATALOG \
    AS TRIGGER_CATALOG, \
  information_schema_tables.TABLE_SCHEMA \
    AS TRIGGER_SCHEMA, \
  triggers.name \
    AS TRIGGER_NAME, \
  CASE \
    WHEN OBJECTPROPERTY(triggers.id, 'ExecIsInsertTrigger') = 1 THEN 'INSERT' \
    WHEN OBJECTPROPERTY(triggers.id, 'ExecIsUpdateTrigger') = 1 THEN 'UPDATE' \
    WHEN OBJECTPROPERTY(triggers.id, 'ExecIsDeleteTrigger') = 1 THEN 'DELETE' \
    ELSE 'UNKNOWN' \
  END \
    AS EVENT_MANIPULATION, \
  information_schema_tables.TABLE_CATALOG \
    AS EVENT_OBJECT_CATALOG, \
  information_schema_tables.TABLE_SCHEMA \
    AS EVENT_OBJECT_SCHEMA, \
  information_schema_tables.TABLE_NAME \
    AS EVENT_OBJECT_TABLE, \
  OBJECT_DEFINITION(OBJECT_ID(information_schema_tables.TABLE_CATALOG + '.' + \
  information_schema_tables.TABLE_SCHEMA + '.' +  triggers.name)) \
    AS ACTION_STATEMENT, \
  CASE \
    WHEN OBJECTPROPERTY(triggers.id, 'ExecIsInsertTrigger') = 1 THEN OBJECTPROPERTY(triggers.id, 'TriggerInsertOrder') \
    WHEN OBJECTPROPERTY(triggers.id, 'ExecIsUpdateTrigger') = 1 THEN OBJECTPROPERTY(triggers.id, 'TriggerUpdateOrder') \
    WHEN OBJECTPROPERTY(triggers.id, 'ExecIsDeleteTrigger') = 1 THEN OBJECTPROPERTY(triggers.id, 'TriggerDeleteOrder') \
    ELSE 1 \
  END \
    AS ACTION_ORDER, \
  '' \
    AS ACTION_CONDITION, \
  'UNKNOWN' \
    AS ACTION_ORIENTATION, \
  CASE \
    WHEN OBJECTPROPERTY(triggers.id, 'ExecIsAfterTrigger') = 1 THEN 'AFTER' \
    ELSE 'INSTEAD OF' \
  END \
    AS CONDITION_TIMING \
FROM \
  sysobjects \
    AS triggers \
  INNER JOIN sysobjects \
    AS tables \
    ON triggers.parent_obj = tables.id \
  INNER JOIN INFORMATION_SCHEMA.TABLES \
    AS information_schema_tables \
    ON tables.name = information_schema_tables.TABLE_NAME \
WHERE \
  triggers.type = 'TR'

select.INFORMATION_SCHEMA.EXT_SYNONYMS=\
SELECT \
  DB_NAME() AS SYNONYM_CATALOG, \
  SCHEMA_NAME(SCHEMA_ID) AS SYNONYM_SCHEMA,  \
  NAME AS SYNONYM_NAME,  \
  PARSENAME(BASE_OBJECT_NAME, 4) AS REFERENCED_OBJECT_SERVER, \
  PARSENAME(BASE_OBJECT_NAME, 3) AS REFERENCED_OBJECT_CATALOG, \
  PARSENAME(BASE_OBJECT_NAME, 2) AS REFERENCED_OBJECT_SCHEMA, \
  PARSENAME(BASE_OBJECT_NAME, 1) AS REFERENCED_OBJECT_NAME \
FROM  \
  SYS.SYNONYMS




© 2015 - 2025 Weber Informatics LLC | Privacy Policy