how to insert the values in 5 table at a time Using any
single statement ?
Answer Posted / pradeep kumar
INSERT INTO MyTable (FirstCol, SecondCol)
SELECT 'First' ,1
UNION ALL
SELECT 'Second' ,2
UNION ALL
SELECT 'Third' ,3
UNION ALL
SELECT 'Fourth' ,4
UNION ALL
SELECT 'Fifth' ,5
| Is This Answer Correct ? | 7 Yes | 2 No |
Post New Answer View All Answers
How to locate and take substrings with charindex() and substring() functions?
What is sql server replication? : sql server replication
What will be the value of @@fetch_status if a row that was a part of the cursor resultset has been deleted from the database after the time the stored procedure that opened the cursor was executed?
What is the default sql server instance name?
How to return the date part only from a sql server datetime datatype?
How to backup encryption key ?
Explain hostprotectionattribute in sql server 2005?
How to query multiple tables jointly?
What are the various editions of sql server 2017 that are available in the market?
What are transactions in sql?
What is difference between order by and group by?
What is the difference between ‘having’ clause and a ‘where’ clause?
Tell me what are the essential components of sql server service broker?
Explain Reporting Life Cycle?
What is a database in ms sql server?