Home > Database > Mysql Tutorial > ACCESS转MSSQL

ACCESS转MSSQL

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-07 15:30:30
Original
1240 people have browsed it

1.Access的数据库中的自动编号类型在转化时, SQL Server并没有将它设为自动编号型,我们需在SQL创建语句中加上identity,表示自动编号. 自动编号设置的字段都会变成非空的字段,这就必须手工修改这些字段,并把他的标示选择是,种子为1,增量为1 2.转化时,

1.Access的数据库中的自动编号类型在转化时, SQL Server

自动编号设置的字段都会变成非空的字段,这就必须手工修改这些字段,并把他的标示选择是,种子为1,增量为1

2.转化时,跟日期有关的字段,SQL SERVER默认为smalldatetime型,我们最好将它变为datetime型,因为datetime型的范围比smalldatetime型大。我遇见这种情况,用smalldatetime型时,转化失败,而用datetime型时,转化成功。

3.对此两种数据库进行操作的sql语句不全相同,例如:在对Access数据库进行删除纪录时用:delete * from user where id=10,而对SQL SERVER数据库进行删除是用:delete user where id=10.

4.日期函数不相同,在对Access数据库处理中,可用date()、time()等函数,但对SQL SERVER数据库处理中,只能用datediff,dateadd等函数,而不能用date()、time()等函数。

5.在对Access数据库处理中,sql语句中直接可以用一些VB的函数,像cstr()函数,而对SQL SERVER数据库处理中,却不能用。

http://qiwu2012.com/sjk/access/69088.html

Related labels:
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
Access error using alias
From 1970-01-01 08:00:00
0
0
0
Single module access
From 1970-01-01 08:00:00
0
0
0
About Mac MAMP PRO deploy thinkphp5.1 access 404
From 1970-01-01 08:00:00
0
0
0
My access page reports 403
From 1970-01-01 08:00:00
0
0
0
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template