Create SQL query file
echo "SELECT 'CacheSession' as table_name, c.name AS column_name, t.name AS data_type, c.length, c.prec AS precision, c.scale, c.isnullable AS nullable, c.colid AS column_order FROM sysobjects o JOIN syscolumns c ON o.id = c.id JOIN systypes t ON c.usertype = t.usertype WHERE o.name = 'CacheSession' AND o.type = 'U' ORDER BY c.colid" > schema_query.sql
Execute and get CSV output
isql -S your_server -U your_user -P your_password -w 65535 -s "," < schema_query.sql > CacheSession_schema.csv
Top comments (0)