CopyPastor

Detecting plagiarism made easy.

Score: 0.9865551341260874; Reported for: String similarity Open both answers

Possible Plagiarism

Plagiarized on 2021-04-19
by Kazi Mohammad Ali Nur

Original Post

Original - Posted on 2009-08-22
by Mike Ritacco



            
Present in both answers; Present only in the new answer; Present only in the old answer;

Microsoft should advertise this functionality of SSMS 2008. The feature you are looking for is built into the **Generate Script** utility, but the functionality is turned off by default and must be enabled when scripting a table.
This is a quick run through to generate the `INSERT` statements for all of the data in your table, using no scripts or add-ins to SQL Management Studio 2008:
1. Right-click on the database and go to **Tasks** > **Generate Scripts**. 2. Select the tables (or objects) that you want to generate the script against. 3. Go to **Set scripting options** tab and click on the **Advanced** button. 4. In the **General** category, go to **Type of data to script** 5. There are 3 options: **Schema Only**, **Data Only**, and **Schema and Data**. Select the appropriate option and click on **OK**.
This answer is collected from below link.
[link to the original answer][1]

[1]: https://stackoverflow.com/questions/982568/what-is-the-best-way-to-auto-generate-insert-statements-for-a-sql-server-table
Microsoft should advertise this functionality of SSMS 2008. The feature you are looking for is built into the **Generate Script** utility, but the functionality is turned off by default and must be enabled when scripting a table.
This is a quick run through to generate the `INSERT` statements for all of the data in your table, using no scripts or add-ins to SQL Management Studio 2008:
1. Right-click on the database and go to **Tasks** > **Generate Scripts**. 2. Select the tables (or objects) that you want to generate the script against. 3. Go to **Set scripting options** tab and click on the **Advanced** button. 4. In the **General** category, go to **Type of data to script** 5. There are 3 options: **Schema Only**, **Data Only**, and **Schema and Data**. Select the appropriate option and click on **OK**. [![SqlDataOptions][1]][1]
You will then get the `CREATE TABLE` statement and all of the `INSERT` statements for the data straight out of SSMS.

[1]: https://i.stack.imgur.com/fWKfA.png

        
Present in both answers; Present only in the new answer; Present only in the old answer;