Home > Database > Mysql Tutorial > body text

将ACCESS的转化为SQL SERVER的体验

WBOY
Release: 2016-06-07 17:46:34
Original
928 people have browsed it

1.ACCESS的数据库中的自动编号类型在转化时,sql server并没有将它设为自动编号型,
  2.转化时,跟日期有关的字段,SQL SERVER默认为smalldatetime型,我们最好将它变为
datetime型,因为datetime型的范围比smalldatetime型大。我遇见这种情况,用
smalldatetime型时,转化失败,而用datetime型时,转化成功。
  3.对此两种数据库进行操作的sql语句不全相同,例如:在对ACCESS数据库进行删除纪录
时用:"delete * from user where id=10",而对SQL SERVER数据库进行删除是用:"delete
  4.日期函数不相同,在对ACCESS数据库处理中,可用date()、time()等函数,但对
  SQL SERVER数据库处理中,只能用datediff,dateadd等函数,而不能用date()、time()等
  5.在对ACCESS数据库处理中,sql语句中直接可以用一些VB的函数,像cstr()函数,而对
SQL SERVER数据库处理中,却不能用。

Related labels:
source:php.cn
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template