In this article, I have explained how to generate SQL Scripts of the table with records and restore it into another database.
Open SQL Server Management Studio. I have created a dummy database and table with some information. Right click on the database, click tasks and generate scripts. In this popup click next. Click Select specific database objects. Select the table you want to generate scripts. Click next. Click single file per object. Click Advanced tab. Select Types of data to script will be “Schema and data". If you need only Schema, then select Schema only. Click ok and next to complete. Scripts has been generated successfully. Now create another database to restore the table with records. Now open the generateD script for the employee table. Change the database name to test and execute scripts. Click “F5” to execute. Now the table has been created successfully with records.
Basics of SQL Server