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

MS SQL Êý¾ÝÀàÐÍ

 
1
bigint     
´Ó -2^63 µ½ 2^63-1 Ö®¼äµÄ integer (ÕûÊý)Êý¾Ý
2
binary       
¶¨³¤µÄbinaryÊý¾Ý£¬×Ϊ8,000×Ö½Ú
3
bit        
integerÊý¾Ý£¬ÖµÎª1»ò0
4
char       
¶¨³¤µÄ·Çunicode characterÊý¾Ý£¬³¤¶ÈΪ8,000¸ö×Ö·û
5
cursor      
 º¬ÓжÔÓαêµÄÒýÓõıäÁ¿»ò´æ´¢¹ý³ÌOUTPUT²ÎÊýËù²ÉÓõÄÊý¾ÝÀàÐÍ
6
datetime    
dateºÍtimeÊý¾Ý£¬´Ó1753Äê1ÔÂ1ÈÕµ½9999Äê12ÔÂ31ÈÕ
7
decimal       
¶¨µã¾«¶ÈºÍСÊýµÄnumericÊý¾Ý£¬´Ó-10^38-1µ½10^38-1Ö®¼ä
8
float       
¸¡µã¾«¶ÈÊý×ÖÊý¾Ý£¬´Ó-1.79E+308µ½1.79E+308Ö®¼ä
9
image       
³¤¶È¿É±äµÄbinaryÊý¾Ý£¬×Ϊ2^31-1×Ö½Ú
10
int       
´Ó-2^31µ½2^31-1Ö®¼äµÄinteger(ÕûÊý)Êý¾Ý
11
money        
monetaryÊý¾ÝÖµ£¬´Ó-2^63µ½2^63-1£¬×¼È·¶ÈΪ»õ±Òµ¥Î»µÄǧ·ÖÖ®Ò»
12
nchar       
¶¨³¤µÄunicodeÊý¾Ý£¬³¤¶ÈΪ4,000¸ö×Ö·û
13
ntext       
³¤¶È¿É±äµÄunicodeÊý¾Ý£¬×Ϊ2^30-1¸ö×Ö·û
14
numeric        
decimalµÄͬÒå´Ê
15
nvarchar   
³¤¶È¿É±äµÄunicodeÊý¾Ý£¬×Ϊ4,000×Ö·û
16
real       
¸¡µã¾«¶ÈÊý×ÖÊý¾Ý£¬´Ó-3.40E+38µ½3.40E+38Ö®¼ä
17
rowversion    
Êý¾Ý¿â·¶Î§ÄÚµÄΨһºÅ
18
smalldatetime    
dateºÍtimeÊý¾Ý£¬´Ó1900Äê1ÔÂ1ÈÕµ½2079Äê6ÔÂ6ÈÕ
19
smallint   
´Ó-2^15µ½2^15-1Ö®¼äµÄintegerÊý¾Ý
20
smallmoney    
monetaryÊý¾ÝÖµ£¬-214,748.3648µ½+214,748.3647Ö®¼ä
21
sql_variant   
¿É´æ´¢¶àÖÖSQL ServerÖ§³ÖµÄÊý¾ÝÀàÐ͵ÄÖµµÄÊý¾ÝÀàÐÍ£¬µ«²»´æ´¢text, ntext, timestampºÍsql_variantÀàÐ͵ÄÖµ
22
sysname    &nb


Ïà¹ØÎĵµ£º

²»ÊÇÆ´SQLÓï¾äµÄÒ³Ãæ´æ´¢¹ý³Ì

ALTER PROCEDURE [dbo].[GetUsersList]
@BigClassID int=0,--´óÀà±ðID
@SmallClassID int=0 ,--СÀà±ðID
@pageindex int=1,
@pagesize int=3,
@ret int output --¹²¼¸Ìõ
AS
set rowcount @pagesize
if @SmallClassID>0
begin
select * from(
select id,BigClassName,SmallClassName,UserName,Corporation,r ......

SQL SERVER ²éѯÓï¾äÓÅ»¯(ת)

1¡¢  ÓóÌÐòÖУ¬±£Ö¤ÔÚʵÏÖ¹¦ÄܵĻù´¡ÉÏ£¬¾¡Á¿¼õÉÙ¶ÔÊý¾Ý¿âµÄ·ÃÎÊ´ÎÊý£»Í¨¹ýËÑË÷²ÎÊý£¬¾¡Á¿¼õÉÙ¶Ô±íµÄ·ÃÎÊÐÐÊý,×îС»¯½á¹û¼¯£¬´Ó¶ø¼õÇáÍøÂ縺µ££»Äܹ»·Ö¿ªµÄ ²Ù×÷¾¡Á¿·Ö¿ª´¦Àí£¬Ìá¸ßÿ´ÎµÄÏìÓ¦ËÙ¶È£»ÔÚÊý¾Ý´°¿ÚʹÓÃSQLʱ£¬¾¡Á¿°ÑʹÓõÄË÷Òý·ÅÔÚÑ¡ÔñµÄÊ×ÁУ»Ëã·¨µÄ½á¹¹¾¡Á¿¼òµ¥£»ÔÚ²éѯʱ£¬²»Òª¹ý¶àµØÊ¹ÓÃͨÅä·û ÈçSELE ......

ÐÔÄÜ¼à¿ØÖ®¼à¿ØSQLÓï¾ä

ÐÔÄÜ¼à¿ØÖ®¼à¿ØSQLÓï¾ä 
·ÖÎö±í 
analyze table tablename compute statistics for all indexes; 
analyze table tablename compute statistics for all indexed columns; 
analyze table tablename compute statistics for table; 
¼à¿ØÊÂÀýµÄµÈ´ý 
select event,sum(decode(wait_Tim ......

SQL 2005 ´´½¨Ô¼Êø

²Î¼û¡¶SQL Sever 2005 Êý¾Ý¿â»ù´¡¼°Ó¦Óü¼Êõ½Ì³ÌÓëʵѵ¡· ÖÜÆæ
 
SQL ServerÖÐÓÐÎåÖÖÔ¼ÊøÀàÐÍ£¬·Ö±ðÊÇCHECKÔ¼Êø¡¢DEFAULTÔ¼Êø¡¢PRIMARY KEYÔ¼Êø¡¢FOREIGN KEYÔ¼ÊøºÍUNIQUEÔ¼Êø¡£
 
1.       CHECKÔ¼Êø£º
CHECKÔ¼ÊøÓÃÓÚÏÞÖÆÊäÈëÒ»Áлò¶àÁеÄÖµµÄ·¶Î§£¬Í¨¹ýÂß¼­±í´ïʽÀ´ÅжÏÊý¾ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ