When the ACCESS database is imported into MSSQL
One problem won't be solved
When access's "automatic number" is automatically included in MSSQL, It is the INT (4) data type, and no primary key is set, not the "id seed"
How can this problem be solved?
The "automatic number" of access can be the INT (4) in MSSQL by default. It identifies the seed and the number of IDS increases by 1.
Select source table and view during data import,
Select the table to be imported,
Click "convert" next to it"
"Create target table" is selected by default. Click "Edit SQL"
(Make sure that there is no target table in the SQL database. Otherwise, you cannot select "create destination table ")
Change the field to be generated as an identifier to the field name [int] identity (1, 1) not null.
For example:
The ID field is the identifier. The original SQL statement is: [ID] [int] not null.
Change to [ID] [int] identity (1, 1) not null
OK
Select enable ID insert"
The following operations are the same as usual: Flying ASP @ tech park
This article comes from xuexiang Network (http://www.snowhack.com)
Address: http://www.snowhack.com/asp/aspxg/tosql/mssqlxg/200901/957.html
Xueyu: A combination of scripts and security, from entry to proficiency, creates the best programming learning site in China