2

The database I'm trying to connect to is "DEV_A" in the following picture,

SQL Server screen shot

I'm trying to get SchemaSpy to connect to it using jTDS. How do I shoehorn these pieces:

  • dbs02
  • ms_2012
  • DEV_A

into these args that SchemaSpy/jTDS is asking me for:

  • -host
  • -db
  • -port (I assume I have to set this to 1433)
  • -u (user)
Jeff Roe
  • 3,147
  • 32
  • 45

1 Answers1

0

Try this...

java -jar "C:\path\to\schemaSpy_5.0.0.jar" -t "C:\path\to\mssql-jtds.properties" -dp "C:\path\to\jtds-1.3.0.jar" -t mssql-jtds -db DEV_A -s dbo -host localhost -port 1433 -u XXXX -p XXXX -o "C:\path\to\output" -hq -gv "C:\path\to\graphviz"

Where "mssql-jtds.properties" is:

description=jTDS JDBC Driver for Microsoft SQL 2000/2005 Server
extends=mssql
connectionSpec=jdbc:jtds:sqlserver://localhost/DEV_A;instance=app
driver=net.sourceforge.jtds.jdbc.Driver
driverPath=/path/to/jtds-1.2.5.jar
dbThreads=1
selectTableCommentsSql=select sys.tables.name as table_name, (select value from sys.extended_properties where sys.extended_properties.major_id = sys.tables.object_id and sys.extended_properties.minor_id = 0) as comments from sys.tables where sys.tables.schema_id=1
selectColumnCommentsSql=select sys.tables.name as table_name, sys.columns.name as column_name, (select value from sys.extended_properties where sys.extended_properties.major_id = sys.columns.object_id and sys.extended_properties.minor_id = sys.columns.column_id) as comments from sys.columns, sys.tables, sys.types, sys.schemas where sys.columns.object_id = sys.tables.object_id and sys.columns.user_type_id=sys.types.user_type_id and sys.tables.schema_id=sys.schemas.schema_id and sys.schemas.name = 'dbo'