SQL Server - Generate script without primary key -
i looking answer can't found it.
i'm trying make generated script of data (i mean, insert commands). because access permissions, can't set identity_insert table off , on (i'm using user application in staging)
so, there way make script in sql server manager , avoid field primary key? set false properties (primary, unique, etc), script still sending field (for e.g., recid 1, 2, 3, etc).
i'm using sql server 2012.
kind regards,
any solution (except remove notepad++) preciated. please ask/edit before downvoted, , sorry english :)
update: configuration script:
results get:
set identity_insert -table- on insert table (id,field1) values (1,'value')
a bit of work around, useful quick , dirty way of doing these things:
select 'insert table (field1) values (''' + field1 + ''')' table
the result set row each insert statement every row in table table. insert statement generated concatenating insert statement text values in field1.
Comments
Post a Comment