![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
SQL
ziwi821
这个作者很懒,什么都没留下…
展开
-
select into 和 insert into select 两种表复制语句
[color=red]select * into destTbl from srcTblinsert into destTbl(fld1, fld2) select fld1, 5 from srcTbl以上两句都是将 srcTbl 的数据插入到 destTbl,但两句又有区别的: 第一句(select into from)要求目标表(destTbl)不存在,因为在插入时...2011-03-21 14:18:11 · 91 阅读 · 0 评论 -
SQL 日期转换 convert
[size=large]Sql Server 中一个非常强大的日期格式化函数Select CONVERT(varchar(100), GETDATE(), 0): 05 16 2006 10:57AMSelect CONVERT(varchar(100), GETDATE(), 1): 05/16/06Select CONVERT(varchar(100), GETDATE(), 2)...2011-03-23 10:07:17 · 79 阅读 · 0 评论 -
SQL2005 时间戳转换成正常时间 日期
今天在做数据移植的时候突然看到一个很奇怪的时间格式。1222115941 后来查了下才知道这个时间戳。以前从来没见过。可是新的数据库的时间格式不是用的时间戳。所以问题就来了。要把时间戳转换成正常时间。在网上找了好多都没找到答案。很杯具。 后来想了下。SQL里面有个DATEADD的函数。时间戳就是一个从1970-01-01 08:00:00到时间的相隔的秒数。所以只要把这个时间戳...2011-03-28 15:39:22 · 271 阅读 · 0 评论 -
Connections could not be acquired from the underlying database
"Connections could not be acquired from the underlying database" 大概意思是说:不能连接当前所配置的数据库.出现这种问题,一般是配置参数有误.若连接mysql数据库的话,这时还要考虑你设置远程mysql.否则,也会出这个问题.远程访问MySQL的设置1.在User表中添加允许远程访问的用户insert into mysql...原创 2013-01-29 10:49:55 · 254 阅读 · 0 评论