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

SQL Server 2005 ¾µÏñ¹¹½¨ÊÖ²á

Ò»¡¢ ¾µÏñ¼ò½é
1¡¢ ¼ò½é
Êý¾Ý¿â¾µÏñÊǽ«Êý¾Ý¿âÊÂÎñ´¦Àí´ÓÒ»¸öSQL ServerÊý¾Ý¿âÒƶ¯µ½²»Í¬SQL Server»·¾³ÖеÄÁíÒ»¸öSQL ServerÊý¾Ý¿âÖС£¾µÏñ²»ÄÜÖ±½Ó·ÃÎÊ;ËüÖ»ÓÃÔÚ´íÎó»Ö¸´µÄÇé¿öϲſÉÒÔ±»·ÃÎÊ¡£
Òª½øÐÐÊý¾Ý¿â¾µÏñËùÐèµÄ×îСÐèÇó°üÀ¨ÁËÁ½¸ö²»Í¬µÄSQL ServerÔËÐл·¾³¡£Ö÷·þÎñÆ÷±»³ÆΪ“Ö÷»ú”£¬µÚ¶þ¸ö·þÎñÆ÷±»³Æ×÷“±¸»ú”¡£Ö÷»úÊý¾Ý¿â¾ÍÊÇÄãʵ¼ÊÓÃ×ŵÄÊý¾Ý¿â£¬¾µÏñÊý¾Ý¿â¾ÍÊÇÄãµÄÊý¾Ý¿âµÄ±¸Óÿ½±´¡£µ±ÊÂÎñдÈëÄãµÄ»ù±¾·þÎñÆ÷µÄʱºò£¬ËûÃÇҲͬÑù±»´«Ë͵½²¢Ð´ÈëÄãµÄ¾µÏñÊý¾Ý¿âÖС£
³ýÁË»ù±¾ºÍ¾µÏñÖ®Í⣬Ä㻹¿ÉÒÔÒýÈëÁíÒ»¸ö¿ÉÑ¡µÄ×é¼þ£¬ÃûΪ“¼ûÖ¤”¡£¼ûÖ¤·þÎñÆ÷ÊǵÚÈý¸öSQL Server 2005ÔËÐÐʵÀý£¬ËüÊÇÔÚÅжÏʲôʱºò½øÐдíÎó»Ö¸´µÄʱºò£¬ÓÃÓÚ»ù±¾ºÍ¾µÏñÖ®¼äÄÚ²¿½»Á÷¡£Ö»Óе±ÄãÏëʵÏÖ×Ô¶¯´íÎó»Ö¸´µÄʱºòÓõ½Õâ¸öÑ¡Ïî¡£ËüʵÏÖÁË2±È1ͶƱµÄÄÜÁ¦£¬µ±ÎÒµÄÒ»¸ö×é¼þ²»¿É´ï£¬²¢Òò´ËÐèÒª½øÐдíÎó»Ö¸´µÄʱºò¡£¼ûÖ¤·þÎñÆ÷Ö»ÓÐÔÚÄãÏëʵÏÖ×Ô¶¯´íÎó»Ö¸´µÄʱºò²ÅÐèÒªÓõ½¡£
2¡¢ Óŵã
ϱíÊÇSQL Server¿ÉÓÃÐÔ¹Ù·½½â¾ö·½°¸µÄÒ»¸ö¶ÔÕÕ±í£¬ÏÖʱÎÒÖÐÐÄʹÓõĻָ´Ä£Ê½ÊÇ“À䱸·Ý”Öеē±¸·Ý/»Ö¸´”£¬Í¨³£À´Ëµ“Èȱ¸·Ý”±È“À䱸·Ý”µÄ¿ÉÓÃÐÔ¸ü¸ß£¬»Ö¸´¸ü¿ì£¬¸üÊʺÏÎÒÖÐÐÄÏÖʱµÄʵ¼ÊÇé¿ö¡£Èç¹û²»´Ó³É±¾¿¼ÂǵĻ°£¬“Èȱ¸·Ý”Öеē¹ÊÕÏתÒÆȺ¼¯”µÄ¿ÉÓÃÐÔÊÇ×î¸ßµÄ£¬µ«ÊǹÊÕÏתÒÆȺ¼¯ÐèÒª½èÖú´ÅÅÌÕóÁжøÇÒ½¨Éè±¾Éí¸´ÔÓÐԽϸߡ£Êý¾Ý¿â¾µÏñµÄ½¨Á¢²¢Ã»ÓÐÌ«¶àµÄÓ²¼þÒªÇó£¬×îÆðÂëûÓÐÏñ“¹ÊÕÏתÒÆȺ¼¯”ÐèÒª¹²Ïí´æ´¢Õâô¸ßµÄÒªÇó¡£
2¡¢ ȱµã
£¨1£©ÓÉÓÚSQL ServerÊÇÒ»¸öʵÀý¶à¸öÊý¾Ý¿âµÄ²úÆ·£¬Êý¾Ý¿â¾µÏñ¼¼ÊõÊÇ»ùÓÚÊý¾Ý¿â¼¶±ðµÄ£¬Òò´Ëÿ´ÎÖ÷Êý¾Ý¿âÐÂÔöÊý¾Ý¿â¶¼±ØÐëΪ±¸»úÔö¼ÓÊý¾Ý¿â²¢ÇÒΪÐÂÔöµÄÊý¾Ý¿â½¨Á¢¾µÏñ¹Øϵ¡£
£¨2£©Êý¾Ý¿âµÄµÇ¼ÃûºÍÓû§ÊÇ´æ´¢ÔÚmasterÊý¾Ý¿â£¬masterÊý¾Ý¿âÊDz»ÄÜ×ö¾µÏñµÄ£¬ËùÒÔÿ´Î²Ù×÷Êý¾Ý¿âµÄµÇ¼ÃûºÍÓû§Ò²ÊÇÐèÒª¶àά»¤Ò»·Ý£¬
£¨3£©Êý¾Ý¿â×÷Òµ²»Äܵõ½ÏàÓ¦µÄά»¤¡£
£¨4£©Î¢ÈíºÅ³Æ¾µÏñ¿ÉÒÔÈÿͻ§¶Ë¶Ô¹ÊÕÏ͸Ã÷£¬µ«ÊÇʵ¼Ê²âÊÔÖз¢ÏÖÖ»ÓÐÂú×ãÌض¨µÄÌõ¼þ²ÅÄÜʵÏÖ͸Ã÷»¯£¬¶øÇÒ͸Ã÷»¯µÃ¿Í»§¶ËÖ§³Ö²Å¿ÉÐУ¨.net Framework 2.0ÒÔÉÏ£¬Microsoft jdbcÇý¶¯ 1.1ÒÔÉÏ£©¡£
£¨5£©¿çÊý¾Ý¿âÊÂÎñºÍ·Ö²¼Ê½ÊÂÎñ¾ù²»Ö§³ÖÊý¾Ý¿â¾µÏñ¡£
×ݹÛÆäËû¼¸ÖÖ·½Ê½£¬½öÓГÈȱ¸·Ý”µÄ“¹ÊÕÏתÒÆȺ¼¯”ûÓÐÕâЩÎÊÌâ¡£
Ò»¡¢ÅäÖÃÖ÷±¸»ú
1¡¢ ÎïÀíÁ¬½Ó


Ïà¹ØÎĵµ£º

Hibernate SQL·½ÑÔ


RDBMS

·½ÑÔ

DB2

org.hibernate.dialect.DB2Dialect

DB2 AS/400

org.hibernate.dialect.DB2400Dialect

DB2 OS390

org.hibernate.dialect.DB2390Dialect

PostgreSQL

org.hib ......

Sql Server²éѯÊý¾Ý¼¯ÐÐÁл¥»»

Ðл»ÁУº
--> Éú³É²âÊÔÊý¾Ý±í: [tb]
IF OBJECT_ID('[tb]') IS NOT NULL
    DROP TABLE [tb]
GO
CREATE TABLE [tb] ([a] [int],[b] [int],[c] [int])
INSERT INTO [tb]
SELECT '3','9','5' UNION ALL
SELECT '5','2','7' UNION ALL
SELECT '6','3','8'
--SELECT * from [tb]
-->SQL²éѯÈçÏ ......

sql³£ÓÃ

select [name] from sysdatabases order by name--µÃµ½Êý¾Ý¿âÖÐËùÓеĿâÃû
select [name] from sysobjects where xtype='U'and [name]<>'dtproperties' order by [name]--µÃµ½Êý¾Ý¿â±íÖеÄÁбí
select [name] from sysobjects where xtype='V' and [name]<>'syssegments' and [name]<>'sysconstraints' ......

SQL µ¼³öµ½ Ö¸¶¨ACCESS±í ÍêÃÀ·½°¸

ÓÉÓÚ³ÌÐòÐèÒª°ÑSQL SERVER ÀïµÄÊý¾Ýµ¼Èëµ½ACCESSÀï.
¸Õ¿ªÊ¼Ê¹ÓÃDataSetÀ´Ñ­»·.
Êý¾ÝÁ¿ÉÙµÄʱºò»¹Ëã¿ÉÒÔÓ¦¸¶µÄ¹ýÀ´.
µ«µ±Êý¾Ý¶àµÄʱºò.
»á±¨´í"λÖôíÎó"
ÔÚÍøÉÏËÑÑ°Ò»·¬.ÕÒµ½Ò»¸ö·½·¨.
ʹÓÃinsert into openrowset
½Ó×Å´íÎóÒ»¸ö½ÓÒ»¸öµÄÀ´..
"²åÈë´íÎó: ÁÐÃû»òËùÌṩֵµÄÊýÄ¿Óë±í¶¨Ò岻ƥÅä¡£"
"δÄÜÕÒµ½ OLE DB Ì ......

SQL¶à¼¶¹ØϵµÄ±íʾ

ÎÒÃÇÒª½¨Á¢¶à¼¶¹Øϵ£¬Ê×ÏÈÐèÒªÁ½¸ö±í.
        µÚÒ»¸ö±í±íʾֱÊô½á¹¹£¬±ÈÈç˵ÎÒÃǹ«Ë¾ÓÐÒ»¸ö²¿ÃÅ¡£¶øÕâ¸ö²¿ÃÅÏ»¹ÓÐ3¸öС×飬ÄÇô3¸öС×éÊôÓÚÕâ¸ö²¿ÃÅ.µÚ¶þ¸ö±í±íʾ¶à²ã½á¹¹,¾ÍÏóµÚÒ»±íÀïÃæËù±íʾµÄ£¬ÕâÈý¸öС×éͬʱ»¹ÊôÓÚ¹«Ë¾.¶øÕâ¸ö¹«Ë¾Í¬Ê±ÊôÓÚÕâ3¸öС×éµÄ¸¸¼¶µÄ¸¸¼¶µÄ²¿ÃÅ¡£¼ÙÈçÎÒ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ