摘要: 功能: 用于备份当前用户所拥有的任何pl/sql objects (包括type,type body, procedure , function, package, package body or java source )原理: 对user_source数据字典的调用,得到任何的pl/sql 代码.使用方法举例:1. 在c盘建立目录c:/export2. 将export_source.sql和extract_source.sql拷贝到c盘根目录.3. 登陆sqlplus , connect scott/tiger4. 运行@c:/export_source.sql5. 执行结束,任何的sco 阅读全文
posted @ 2008-06-17 15:14 dainiao01 阅读(176) 评论(0) 推荐(0) 编辑
摘要: /* t_stock 库存表 stockid 流水号 goodscode 商品编码 areaid 地区编码 goodsnumber 商品个数 stockprice 总价值 t_goods商品信息表 goodscode 商品编码 goodsmodel goodsname 商品名称 goodsprice 价格 goodstypeid 类型ID 语句功能 更新库存表中的总价值字段为商品个数*商品价格 IP 192.168.1.71 oracle 服务名 :xinodata 用户名:bjgluserv... 阅读全文
posted @ 2008-06-17 15:05 dainiao01 阅读(228) 评论(0) 推荐(0) 编辑
摘要: 日月明王http://sunmoonking.spaces.live.com今天写了个复杂的SQL,用来更新另一个表select vin,(max(in_mileage)-min(in_mileage))/(max(start_time)-min(start_time)) from (select vin,in_mileage,start_timefrom (select vin,in_mileage,start_time ,row_number() over (partition by vin order by start_time) wwmnum from(select vin,max(i 阅读全文
posted @ 2008-06-17 15:03 dainiao01 阅读(6228) 评论(0) 推荐(0) 编辑
摘要: SQL> set echo on SQL> set time on 17:56:09 SQL> set timing on 17:56:12 SQL> set autotrace traceonly 17:56:19 SQL> @aaa.sql 17:56:21 SQL> update ( 17:56:21 2 select /*+use_hash(a,b)*/a.bill_bal bill_bal_a ,b.bill_bal bill_bal_b 17:56:21 3 from tjw_target_user a,tmp_tjw b 17:56:21 4 阅读全文
posted @ 2008-06-17 15:02 dainiao01 阅读(527) 评论(0) 推荐(0) 编辑