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

ÇósqlÓï¾ä½«Êý¾Ý¿â±íijЩ×ֶεÄÄÚÈÝ·­10±¶

Êý¾Ý¿âij±í£¬Ï뽫ÆäÖÐf1,f2Á½¸ö×ֶεÄÄÚÈÝ·­10±¶£¬Çë½ÌÈçºÎд·¨£¿
update tbl set f1= f1*10£¬f2= f2*10 where id=10451
ÕâÖÖд·¨»áÔì³Éplsql¿¨ËÀ
²»»á°É£¬ÄǸöid=10451 µÄÊý¾ÝÓжàÉÙ°¡~~~~

ÎÒ¹À¼ÆsqlÊDz»ÊDz»Ö§³Ö f1= f1*10ÕâÖÖд·¨£¬Õâ¸ö¼´Ê¹ÊÇÒ»ÌõÊý¾Ý¶¼»á¿¨ËÀ

Ö§³Ö°¡£¬ÍêÈ«¿ÉÒÔ£¬ÓдíÎóÂð£¿ÄãдµÄ~~~·

update tbl set f1= f1*10,f2= f2*10 where id=10451

select * from tb1 where id=10451 ËٶȿìÂð
¿ÉÄܺÍË÷ÒýÌ«¶àÓйØ

²»ºÃÒâ˼£¬ ÊÇ±í±»ËøסÁË¡£¡£¡£¡£½áÌù


ÎÒ¹À¼ÆsqlÊDz»ÊDz»Ö§³Ö f1= f1*10ÕâÖÖд·¨£¬Õâ¸ö¼´Ê¹ÊÇÒ»ÌõÊý¾Ý¶¼»á¿¨ËÀ


Õâ¸öÊÇÖ§³ÖµÄ Ö»²»¹ý Êý¾Ý¶àÁË ËٶȺÜÂý

update tbl set f1= f1*10,f2= f2*10 where id=10451


Ïà¹ØÎÊ´ð£º

Çë½ÌÒ»¸öSQLÓ¦ÓÃÎÊÌâ

ÓÐʱºòÔÚÊý¾ÝÖвéѯÊý¾ÝµÄʱºò¿¼ÂÇÐÔÄÜÎÊÌ⣬»á½«¸´ÔÓÓï¾ä²ð·Ö»ò½èÓÃÁÙʱ±íÀ´¶à´Î²éѯ×îÖյõ½ÏëÒªµÄÊý¾Ý£¬ÏÖÔÚ½«ÕâЩ²éѯÄÚÈÝ×ö³É±¨±í£¬ÐèҪд¸öÓï¾äÒ»ÆøºÇ³É¡£
ÎÒÏëÎʵÄSQLÊÇ·ñ¿ÉÒÔÔÚ²éѯÓï¾äÒ»½áÊøºó£¬ÔÙ×Ô¶¯Ô ......

ÇóÕâ¾äSqlÈçºÎÀí½â

create table [¿Í»§ÁªÏµ±í]([¿Í»§±àºÅ] varchar(2),[ÁªÏµÈÕÆÚ] datetime,[ÁªÏµÄÚÈÝ] int)
insert [¿Í»§ÁªÏµ±í]
select 'aa','2009/01/01',111 union all
select 'bb','2009/02 ......

SQLÓï¾äÎÊÌâ

create trigger TR_Delete_pm_WorkCard
on pm_WorkCard
for delete
as
if @@rowcount=0 return
begin tran
  update pm_PlanEntry
  set FDispatchQty=t4.FDispatchQty - t1.FDispat ......

ÇóSQLÓï¾ä¿ØÖÆÒ»ÁеÄÖµ

ÄÄλ¸ßÊÖÌṩһ¸öSQlÓï¾ä£¬¿ØÖƱíÖÐÖ¸¶¨ÁеÄÖµ±ØÐëÊÇÕýÊý£¿
ÔÚ³ÌÐòÀïÃæÅжϲ»ºÃÂ𣿣¿

Äã¿ÉÒÔÔÚ½¨±íµÄʱºòÓÃcheckÔ¼Êø±íÖеĸÃ×Ö¶Îѽ£¡
È磺
create table tab_name£¨
name varchar2(20),
age numbe ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ