SQLÓï¾äʾÀý
--²éѯÊý¾Ý
SELECT *
from main_table;
--Ìí¼ÓÊôÐÔ
ALTER TABLE main_table
ADD AcctStop_Time SMALLDATETIME NULL;
--²åÈëÐÂÊý¾Ý
INSERT INTO main_table(Digital_ID, Letter_ID, User_Password, On_Line, IP, AcctStop_Time, FriendTable_UpdaeTime)
VALUES(10000000 + IDENT_CURRENT('main_table') + IDENT_INCR('main_table'), 'ttl', 666666, 0, 192168001025, GetDate(),GetDate());
--ÐÞ¸ÄÐÐÐÅÏ¢
UPDATE main_table
SET Digital_ID = 1000000+3, Letter_ID = 'ttoob'
WHERE Digital_Mark = 3
--Ìí¼ÓΨһÐÔÔ¼Êø
ALTER TABLE main_table
ADD CONSTRAINT user_id_key UNIQUE(Digital_ID);
--ɾ³ýΨһÐÔÔ¼Êø
ALTER TABLE main_table
DROP CONSTRAINT user_id_key
--»ñµÃ±í½á¹¹ SQLServer2000Ï¿ÉÓá£
exec sp_columns '±íÃû'
Ïà¹ØÎĵµ£º
1.´ò¿ªSQL server enterprise mananger “ÆóÒµ¹ÜÀíÆ÷”
ÔÚÄãÒªµ¼³öµÄSQLÊý¾Ý¿âÉÏÊó±êÓÒ¼ü²Ëµ¥£ºËùÓÐÈÎÎñ-¡·µ¼³öÊý¾Ý
2.»Ø³öÏÖÒ»¸öµ¼³öÏòµ¼´°¿Ú¡£
Ñ¡Ôñ±»µ¼³öµÄÊý¾ÝÔ´£¬ÎªÄã¸Õ²ÅËùÑ¡ÔñµÄÊý¾Ý¿â£¬Èç¹û·¢ÏÖ²»¶ÔÓ¦×ÔÐÐÐ޸ġ£
3.½øÈëµ¼³öµ½Ä¿±êÊý¾ÝÔ´µÄÑ¡Ôñ£¬ÕâÀïÎÒÃÇҪת³ÉACCESSµÄÊý¾Ý¿â¡£×¢ÒâÑ¡ÔñÊý¾ÝÔ´ÀàÐÍÎ ......
declare @tmp_table table(tempvalue varchar(100) null)
insert into @tmp_table
select optname from dbo.MSreplication_options
select * from @tmp_table
alter table testTable
(
decimal_field decimal null,
datetime_field datetime null,
money_field money null, ......
1.×î»ù±¾µÄDBMS_OUTPUT.PUT_LINE()·½·¨¡£
¡¡¡¡Ëæ±ãÔÚʲôµØ·½£¬Ö»ÒªÊÇBEGINºÍENDÖ®¼ä£¬¾Í¿ÉÒÔʹÓÃDBMS_OUTPUT.PUT_LINE(output);È»¶øÕâ»áÓÐÒ»¸öÎÊÌ⣬¾ÍÊÇʹÓøú¯ÊýÒ»´Î×î¶àÖ»¿ÉÒÔÏÔʾ255¸ö×Ö·û£¬·ñÔò»º³åÇø»áÒç³ö¡£
¡¡¡¡´ËÍ⣬º¯ÊýDBMS_OUTPUT.ENABLE(20000)ÕâÖÖº¯Êý£¬½ö½öÊÇÉèÖÃÕû¸ö¹ý³ÌµÄÈ«²¿Êä³ö»º³åÇø´óС£¬¶ø·ÇDBM ......