SQL Server Table with data
SELECT * FROM TABLENAME
That will give you data. lol
Right click on the Database, go to Generate skript, inside 'advanced' ( I believe) it says 'schema' and 'Schema and Data' select 'Schema and Data' one.
Or
SELECT *
INTO newtable (it will create a new table)FROM tableName (you want to create a table using this table data)
Hope it helps.
Last edited: 27-Jul-19 08:35 AM
Hello smtzac,
Thank you for your reply.
Is there a query to generate a query as an alternative by going into the database>tasks>generate skript.......?
Thank you.
Last edited: 28-Jul-19 01:23 PM
No, I don't believe so.
Last edited: 28-Jul-19 09:22 AM
Copy the result set from the following query and patch with INSERT INTO dbo.DestinationTable(ColumnA,ColumnB)
SELECT 'SELECT '+ ''+ColumnA+''+','+''+ColumnB+''+' UNION ALL'
FROM dbo.TableName
Please log in to reply to this post
You can also log in using your Facebook
What people are reading
You might like these other discussions...
· Posts 3
· Viewed 741
· Likes 2
· Posts 8
· Viewed 815
· Likes 1