SQL Server database export

SQL Server database export

Today, when I gave the source code of other students' management system, I didn't know how to export the database (actually, it won't be long, I'm too lazy to check it, and I did a good Google today and recorded it). Don't say much, just do it directly.

  1. First open SQL Server (a bit nonsense)
    Insert picture description here

  2. Find the database to be exported
    Insert picture description here

  3. Right click -> Task -> Generate script
    Insert picture description here

  4. Click next
    Insert picture description here

  5. Select the directory, click Advanced, in the pop-up "Advanced scripting options", pull down the drop-down bar to the bottom, set the "data type to be scripted" to "data only" ("data only" means only export data as insert statements , If it is to export the table structure, select "Schema Only", select "Schema and Data", the schema and insert statement will be generated), press the "OK" button:Insert picture description hereInsert picture description here

  6. Continue to click Next until it is completed.Insert picture description here

  7. View the saved file, and finally a new query window will be created automatically, and all data in the table will be converted into insert statements.
    Insert picture description here

Guess you like

Origin blog.csdn.net/m0_43456002/article/details/105390643