ITPUB个人空间 »
JackieWLB的个人空间
欢迎访问 JackieWLB 的个人空间
我的论坛主题
-
2008-06-27 22:13:16 / Oracle开发
现有一张表,有很多列,现在只关心3列,其余省略time date,id varchar2,cost numbertime列有索引假设表示每个会员在每个时间点的消费现在id列大概有将近1000个不同的值现在想查找某个时间段,某个id,cost大于指定值的第一个时间点和cost值。例如要查找id为“张三”的会员在2008年1月到3月之间cost>500的第一个值。请问如何写sql可以提高响应速度。我这边是在vc++环境下,利用OO4O连接oracle我试过1。直接selectselect time,value from table_name where (time between .. and ..) and id = ..and value
查看(543)
评论(10)
-
2008-03-19 17:16:56 / Oracle开发
现有一带索引的表,要一直不停的执行INSERT请问将索引段的INITRANS参数设置的稍微大点能提高INSERT的效率么?
查看(209)
评论(3)
-
2008-03-19 09:35:53 / Oracle开发
The SORT_AREA_SIZE is generally allocated out of your PGA~~~~~~~~~~and the SORT_AREA_RETAINED_SIZE will be in your UGA.排序区不是在PGA中的嘛?
查看(260)
评论(3)
-
2008-03-18 20:12:51 / Oracle开发
出错时的操作:通过VC程序向数据库INSERT记录!alert.log里的信息:Tue Mar 18 17:28:23 2008Errors in file f:\oracle\product\10.1.0\admin\test\udump\test_ora_3492.trc:Tue Mar 18 17:28:26 2008Errors in file f:\oracle\product\10.1.0\admin\test\udump\test_ora_1760.trc:以下是打开跟踪文件得到的信息:Dump file f:\oracle\product\10.1.0\admin\test\udump\test_ora_3492.trcTue Mar 18 17:28:23 2008ORACLE V10.1.0.2.0 - Production vsnsta=0vsnsql=13 vsnxtr=3Oracle Database 10g Enterpr
查看(209)
评论(1)
-
2008-03-17 13:46:30 / Oracle开发
环境:vc++ 中使用OO4O连接ORACLE。使用数组传递参数!方法一:直接用INSERT INTO TABLE_NAME VALUES(:数组1,:数组2……);方法二:首先创建包create package my_packageas type t1 as table of table_name.col1%type index by binary_integer;type t2 as table of table_name.col2%type index by binary_integer;……end my_package;创建存储过程如下:create procedure pro_input(v1 in my_package.t1,v2 in my_package.t2,....)asbeginforall i in v1.first...v1.lastinsert
查看(312)
评论(8)
-
2008-03-17 10:24:07 / Oracle开发
PGA的内存使用如何限制!我有个应用程序运行时,需要一直连着ORACLE,在运行的时候,process和session 并没有太多变化但是ORACLE进程占用的内存确一直增大是不是因为PGA部分内存不能及时释放?试过sort_area_retained_size参数,也没什么用!只有断开连接才释放内存!请问如何解决该问题!
查看(244)
评论(3)
-
2008-03-11 21:02:48 / Oracle开发
直接创建SEQUENCE没任何问题为什么在包里动态创建的时候会有权限不足的错误 ?
查看(331)
评论(3)
-
2008-03-11 20:11:25 / Oracle开发
简单创建包如下:create or replace package testasprocedure p1();end test;create or replace packagebody testasprocedure p1()asbegin代码段1;if ……then代码段2;endif;end p1;end test;问题如下:代码段2中含有动态sql,请问按照上面的写法和把代码段2写成另一个过程再调用的效率一样嘛?如果不一样,哪个效率更高点?
查看(258)
评论(5)
-
2008-03-07 10:23:35 / Oracle开发
在包中定义一个变量和一个过程在过程的调用中改变变量的值请问变量值是不是只被初始化一次?该变量是不是可以做为统计过程调用次数?例如:create or replace package testasp_x number :=0;procedure change_x();end test;create or replace package body testasprocedure change_x()as begin…………x :=x+1;end;包只编译一次,是不是以后不管什么时候调用包里的存储过程调用了多少次,x的值就应该是多少吧(当然不超过NUMBER范围的情况下)?
查看(450)
评论(14)
-
2008-03-06 17:34:46 / Oracle开发
不知道怎么看 呵呵
查看(402)
评论(10)