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

ADOÖÐsqlserver´æ´¢¹ý³ÌʹÓÃ

ADOÖÐsqlserver´æ´¢¹ý³ÌʹÓà ÊÕ²Ø
´ÓADOÖеõ½¶à¸ö¼Ç¼¼¯ÒÔ¼°ÔõôÑùÔÚADOÖÐʹÓÃsql server µÄ´æ´¢¹ý³Ì
DataType Value Length Data Length
BIGINT 996857543543543 15 8
INT 543543 6 4
SMALLINT 32765 5 2
TINYINT 254 3 1
BIT True 1 1
DECIMAL 765.5432321 11 9
NUMERIC 432.6544 8 5
MONEY 543.1234 6 8
SMALLMONEY 543.1234 6 4
FLOAT 5.4E+54 8 8
REAL 2.43E+24 9 4
DATETIME 8/31/2003 11:55:25 PM 19 8
SMALLDATETIME 8/31/2003 11:55:00 PM 19 4
CHAR QWE  3 4
VARCHAR Variable! 9 9
TEXT     307
NCHAR WIDE 4 8
NVARCHAR   0 0
NTEXT     614
GUID {58F94A80-B839-4B35-B73C-7F4B4D336C3C} 36 16
Return Value: 0
CREATE PROCEDURE "dbo"."DataTypeTester"
     @myBigInt bigint
     , @myInt int
     , @mySmallint smallint
     , @myTinyint tinyint
     , @myBit bit
     , @myDecimal decimal(10, 7)
     , @myNumeric numeric(7, 4)
     , @myMoney money
     , @mySmallMoney smallmoney
     , @myFloat float
     , @myReal real
     , @myDatetime datetime
     , @mySmallDatetime smalldatetime
     , @myChar char(4)
     , @myVarchar varchar(10)
     , @myText text
     , @myNChar nchar(4)
     , @myNVarchar nvarchar(10)
     , @myNText ntext
     , @myGuid uniqueidentifier
 AS
 
 SELECT 'BIGINT' "DataType", @myBigInt "Value" , LEN(@myBigInt) "Length"              , DATALENGTH(@myBigInt) "Data Length"
 SELECT 'INT'              , @myInt  &nb


Ïà¹ØÎĵµ£º

sqlserver 2000 Ô¶³ÌÁ¬½Ó ·þÎñÆ÷µÄ½â¾ö·½°¸

sqlserver 2000 Ô¶³ÌÁ¬½Ó ·þÎñÆ÷µÄ½â¾ö·½°¸
Ïêϸ³ö´¦²Î¿¼£ºhttp://www.jb51.net/article/18774.htm
¾ßÌå²½Ö裺
Ò»¡¢ping·þÎñÆ÷IPÄÜ·ñpingͨ
¹Û²ìÔ¶³ÌSQL Server 2000·þÎñÆ÷µÄÎïÀíÁ¬½ÓÊÇ·ñ´æÔÚ¡£Èç¹û²»ÐУ¬Çë¼ì²éÍøÂ磬²é¿´ÅäÖ㬵±È»µÃÈ·±£Ô¶³Ìsql server 2000·þÎñÆ÷µÄIPƴдÕýÈ·¡£
¶þ ÔÚDos»òÃüÁîÐÐÏÂÊäÈëtelnet · ......

°²×°SqlServer 2000ʱ³öÏÖÒì³£µÄ´¦Àí


ÏÖÏó£º
ÔÚ×°SqlServer 2000ʱ£¬ÀÏÊǵ¯³ö“ÁíÒ»¸öʵÀýÕýÔÚÔËÐДµÄ´íÎóÐÅÏ¢£¬½áÊøÁ˽ø³ÌÀïsqlµÄÏà¹ØÎļþºÍɾ³ýÒÔÇ°°²×°¹ýµÄ°²×°Ä¿Â¼ÏµÄsqlÎļþºó£¬ÖØÆôµçÄÔºó°²×°»¹ÊdzöÏÖÕâÖÖÇé¿ö¡£
´¦Àí°ì·¨£º
ÕâÖÖÇé¿öÒ»°ãÊÇSqlServer 2000жÔز»ÍêÈ«Ôì³ÉµÄ¡£
ÔÚ“¿ªÊ¼-ÔËÐДÖÐÊäÈëregeditµ÷³ö×¢²á±í£¬ÕÒµ½£ ......

sqlserverºÍoracle³£Óú¯Êý¶Ô±È

sqlserverºÍoracle³£Óú¯Êý¶Ô±È
Êýѧº¯Êý
¡¡¡¡1.¾ø¶ÔÖµ
¡¡¡¡S:select abs(-1) value
¡¡¡¡O:select abs(-1) value from dual
¡¡¡¡2.È¡Õû(´ó)
¡¡¡¡S:select ceiling(-1.001) value
¡¡¡¡O:select ceil(-1.001) value from dual
¡¡¡¡3.È¡Õû£¨Ð¡£©
¡¡¡¡S:select floor(-1.001) value
¡¡¡¡O:select floor(-1.0 ......

SQLServerÊý¾Ý¿âÉè¼Æ±íºÍ×Ö¶Î(ת)

SQL ServerÊý¾Ý¿âÉè¼Æ±íºÍ×Ö¶Î
1. ԭʼµ¥¾ÝÓëʵÌåÖ®¼äµÄ¹Øϵ
¡¡¡¡¿ÉÒÔÊÇÒ»¶ÔÒ»¡¢Ò»¶Ô¶à¡¢¶à¶Ô¶àµÄ¹Øϵ¡£ÔÚÒ»°ãÇé¿öÏ£¬ËüÃÇÊÇÒ»¶ÔÒ»µÄ¹Øϵ£º¼´Ò»ÕÅԭʼµ¥¾Ý¶ÔÓ¦ÇÒÖ»¶ÔÓ¦Ò»¸öʵÌå¡£ÔÚÌØÊâÇé¿öÏ£¬ËüÃÇ¿ÉÄÜÊÇÒ»¶Ô¶à»ò¶à¶ÔÒ»µÄ¹Øϵ£¬¼´Ò»ÕÅԭʼµ¥Ö¤¶ÔÓ¦¶à¸öʵÌ壬»ò¶àÕÅԭʼµ¥Ö¤¶ÔÓ¦Ò»¸öʵÌå¡£ÕâÀïµÄʵÌå¿ÉÒÔÀí½âΪ»ù±¾±í¡£Ã ......

sqlserverÊý¾Ý¿âDateTime¸ñʽ²Ù×÷

Êý¾ÝÀï(sqlserver) µÄ²Ù×÷ £º
eg £º2008-3-31 10:34 --> 2008-3-31
Ò».½ØÈ¡×Ö·û´®·½Ê½
select substring('2008-3-31 10:34',0,charindex(' ','2008-3-31 10:34'))
¶þ.
Select
CONVERT(varchar, getdate(), 1),--mm/dd/yy
CONVERT(varchar, getdate(), 2),--yy.mm.dd
CONVERT(varchar, getdate() ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ