Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

sqlÓï¾ä ½Øȡʱ¼ä Ö»ÏÔʾ Ä꣬Ô£¬Èյĸñʽ


Õª×Ôhttp://blog.sina.com.cn/zhm85
SQLÓï¾ä½Øȡʱ¼ä£¬Ö»ÏÔʾÄêÔÂÈÕ£¨2004-09-12£©
select CONVERT(varchar, getdate(), 120 )
‘getdate£¨£©’¸ÄΪʱ¼ä×Ö¶ÎÃû‘createtime’
ÔÙÖØÃüÃûмÓÁУ¨Select Name AS UName from Users£©
ÀýÈç select convert(varchar(11),createtime,120) as Ndate from UserS
ÈÕÆÚ½ØÈ¡ÏÔʾ¸ñʽ
select CONVERT(varchar, getdate(), 120 )
2004-09-12 11:06:08
select replace(replace(replace(CONVERT(varchar, getdate(), 120 ),\'-\',\'\'),\' \',\'\'),\':\',\'\')
20040912110608
select CONVERT(varchar(12) , getdate(), 111 )
2004/09/12
select CONVERT(varchar(12) , getdate(), 112 )
20040912
select CONVERT(varchar(12) , getdate(), 102 )
2004.09.12
select CONVERT(varchar(12) , getdate(), 101 )
09/12/2004
select CONVERT(varchar(12) , getdate(), 103 )
12/09/2004
select CONVERT(varchar(12) , getdate(), 104 )
12.09.2004
select CONVERT(varchar(12) , getdate(), 105 )
12-09-2004
select CONVERT(varchar(12) , getdate(), 106 )
12 09 2004
select CONVERT(varchar(12) , getdate(), 107 )
09 12, 2004
select CONVERT(varchar(12) , getdate(), 108 )
11:06:08
select CONVERT(varchar(12) , getdate(), 109 )
09 12 2004 1
select CONVERT(varchar(12) , getdate(), 110 )
09-12-2004
select CONVERT(varchar(12) , getdate(), 113 )
12 09 2004 1
select CONVERT(varchar(12) , getdate(), 114 )
11:06:08.177


Ïà¹ØÎĵµ£º

[ÊÕ£] ÓÃsqlite Ö´Ðбê×¼ sql Óï·¨

http://www.umgr.com/blog/PostView.aspx?bpId=36294
 1. Ö´ÐÐsqlÓï¾ä
int sqlite3_exec(sqlite3*£¬ const char *sql£¬ sqlite3_callbacksql Óï·¨
£¬ void *£¬  char **errmsg );
Õâ¾ÍÊÇÖ´ÐÐÒ»Ìõ sql Óï¾äµÄº¯Êý¡£
µÚ1¸ö²ÎÊý²»ÔÙ˵ÁË£¬ÊÇÇ°Ãæopenº¯ÊýµÃµ½µÄÖ¸Õ롣˵ÁËÊǹؼüÊý¾Ý½á¹¹¡£
µÚ2¸ö²ÎÊýconst char ......

Excel´ò¿ª´ÓPL/SQL Deleveloperµ¼³öµÄcsvÎļþÂÒÂëÎÊÌâ

ÓÃPL/SQL Deleveloperµ¼³öcsvÎļþ¸ñʽÊý¾Ý£¬ÓÃexcel´ò¿ªÊÇÂÒÂ룬ÓüÇʱ¾´ò¿ªÕý³££¬Ôõô»ØÊ£¿
ÂíÉÏGoogle£¬Ô­À´µ¼³öµÄÎļþµÄ±àÂë¸ñʽÊÇUTF-8ºÍ¶øexcelĬÈÏ´ò¿ªÎļþµÄ±àÂëÊÇunicode£¬ÓÚÊÇ£º
1¡¢ÓüÇʱ¾´ò¿ªÎļþ£¬È»ºóÁí´æΪ£¬ÌîдÎļþÃû£¬Ñ¡Ôñ±àÂë¸ñʽΪunicode
2¡¢ÓÃexcel´ò¿ªÐµÄÎļþ£¬Õý³£ÏÔʾ
µ«ÊdzöÏÖÁíÍâµÄÎÊÌ⣠......

SQLÊý¾Ý¿â

1.      ´æ´¢¹ý³Ì(¶¨Òå&±àд)
l  ´´½¨´æ´¢¹ý³Ì
CREATE PROCEDURE storedproc1
AS
SELECT *
from tb_project
WHERE  Ô¤¼Æ¹¤ÆÚ<= 90
ORDER BY  Ô¤¼Æ¹¤ÆÚ DESC
GO
exec storedproc1
GO
 
l   Ð޸Ĵ洢¹ý³Ì
ALTER PROCEDURE storedproc1
AS
SEL ......

ά»¤SQL serverµÄ28¸öСÎÊÌâ

1.ÈçºÎ´´½¨Êý¾Ý¿â
CREATE DATABASE student
2.ÈçºÎɾ³ýÊý¾Ý¿â
DROP DATABASE student
3.ÈçºÎ±¸·ÝÊý¾Ý¿âµ½´ÅÅÌÎļþ
BACKUP DATABASE student to disk=´c:S4.bak´
4.ÈçºÎ´Ó´ÅÅÌÎļþ»¹Ô­Êý¾Ý¿â
RESTORE DATABASE studnet from DISK = ´c:S4.bak´
5.ÔõÑù´´½¨±í£¿
CREATE TABLE Students (
&n ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ