Oracle Strange Long query

Hello,
I'm still in the process of finding what is wrong with my oracle connection.
Everytime a request is done, this query is executed:
SELECT NULL AS table_cat, t.owner AS table_schem,t.table_name AS
table_name,t.column_name AS column_name, DECODE (t.data_type, 'CHAR',
1, 'CLOB', 2005, 'BLOB', 2004, 'VARCHAR2', 12, 'NUMBER', 3, 'LONG',
-1, 'DATE', 93,'RAW', -3, 'LONG RAW', -4, 'BINARY_FLOAT', 7,
'BINARY_DOUBLE', 8, 'XMLTYPE',2005, 'BFILE',2004,'NCHAR',1,
'NVARCHAR2',12, 'NCLOB', 2005, 'ROWID', 12, 'FLOAT', 8, 1111) AS
data_type, t.data_type AS type_name, decode(t.data_type, 'NUMBER',
decode(t.data_precision, null, decode(t.data_scale, null, 0, 0, 38,
t.data_scale), t.data_precision), 'FLOAT', 15, 'CLOB',2147483647,
'NCLOB', 2147483647, 'LONG', 2147483647, 'BLOB', 2147483647, 'LONG
RAW', 2147483647, 'BFILE', 2147483647, 'DATE', 19, 'ROWID', 18,
'BINARY_FLOAT', 7, 'BINARY_DOUBLE', 15,decode(t.data_length, 0, 1,
t.data_length)) as column_size, 0 AS buffer_length,
decode(t.data_type, 'NUMBER', decode(t.data_scale, null,
decode(t.data_precision, null, 0,null), t.data_scale), 'FLOAT',
NULL,'DATE', 0, NULL) AS decimal_digits, decode(t.data_type,
'BINARY_FLOAT', 10, 'BINARY_DOUBLE', 10, 'FLOAT', 10, 'NUMBER', 10,
NULL) AS num_prec_radix, DECODE (t.nullable, 'N', 0, 1) AS nullable,
NULL AS remarks,NULL AS column_def, null AS sql_data_type, null AS
sql_datetime_sub, decode(t.data_type, 'VARCHAR2',
decode(t.data_length, 0, 1, t.data_length), 'CHAR', t.data_length,
'NCHAR', t.data_length, 'CLOB', 2147483647, 'NCLOB', 2147483647,
'LONG', 2147483647, 'BFILE', 2147483647, NULL) AS char_octet_length,
t.column_id AS ordinal_position, DECODE (t.nullable, 'N', 'NO', 'YES')
AS is_nullable, null as SCOPE_CATLOG, null as SCOPE_SCHEMA, null as
SCOPE_TABLE, null as SOURCE_DATA_TYPE FROM all_tab_columns t WHERE
t.owner LIKE 'REI' ESCAPE '\' AND t.table_name LIKE 'G_PAGE' ESCAPE
'\' AND t.column_name LIKE '%' ESCAPE '\' UNION ALL SELECT NULL,
asy.owner, asy.synonym_name , t.column_name, DECODE (t.data_type,
'CHAR', 1, 'CLOB', 2005, 'BLOB', 2004, 'VARCHAR2', 12, 'NUMBER', 3,
'LONG', -1, 'DATE', 93,'RAW', -3, 'LONG RAW', -4, 'BINARY_FLOAT', 7,
'BINARY_DOUBLE', 8, 'XMLTYPE',2005, 'BFILE',2004,'NCHAR',1,
'NVARCHAR2',12, 'NCLOB', 2005, 'ROWID', 12, 'FLOAT', 8, 1111),
t.data_type, decode(t.data_type, 'NUMBER', decode(t.data_precision,
null, decode(t.data_scale, null, 0, 0, 38, t.data_scale),
t.data_precision), 'FLOAT', 15, 'CLOB',2147483647, 'NCLOB',
2147483647, 'LONG', 2147483647, 'BLOB', 2147483647, 'LONG
RAW',2147483647, 'BFILE', 2147483647, 'DATE', 19, 'ROWID', 18,
'BINARY_FLOAT', 7, 'BINARY_DOUBLE', 15,decode(t.data_length, 0, 1,
t.data_length)), 0, decode(t.data_type, 'NUMBER', nvl(t.data_scale,
0), 'DATE', 0, 'FLOAT', NULL, NULL) AS decimal_digits,
decode(t.data_type, 'FLOAT', 10, 'NUMBER', 10, NULL), DECODE
(t.nullable, 'N', 0, 1), NULL, NULL, null, null, decode(t.data_type,
'VARCHAR2', decode(t.data_length, 0, 1, t.data_length), 'CHAR',
t.data_length, 'NCHAR', t.data_length, 'CLOB', 2147483647, 'NCLOB',
2147483647, 'LONG', 2147483647, 'BFILE', 2147483647, NULL),
t.column_id, DECODE (t.nullable, 'N', 'NO', 'YES'), null, null, null,
null FROM all_synonyms asy, all_tab_columns t WHERE t.table_name =
asy.table_name AND t.owner = asy.table_owner AND t.column_name LIKE
'%' ESCAPE '\' AND asy.owner LIKE 'REI' ESCAPE '\' AND
asy.synonym_name LIKE 'G_PAGE' ESCAPE '\' ORDER BY table_schem,
table_name, ordinal_positionThis is a very long and resource consuming query.
Why this query is executed everytime I do a commit, select or anything.
A commit is 30 sec long (http://swforum.sun.com/jive/thread.jspa?threadID=93759&tstart=0).
Are all Oracle users subject to this problem?
Regards
Kuon

Here's my theory:
Oracle's jdbc driver (not Sun's) doesn't support rowset.getMetaData() until the query statement is executed. I understand that the database itself doesn't have support. (a year ago this was a problem, I still think so now).
Sun's jdbc driver for Oracle (repackaged from DataDirect) does support rowset.getMetatData().
So how does it do this? I don't know exactly, but the only way I can think of is that it is to parse the query, get the database meta data, and use all that to determine the resultSet meta data.
I think you're seeing the "get the database meta data" request, and that's just taking along time.
I'd expect that data to be cached by the driver on (at least) a per-connection basis. Doesn't look like though.
Maybe someone from Sun has the current scoop for plans in this area.
In the meantime, I think you're hosed if you want to use a CachedRowSet.
Workarounds would be using plain old jdbc, hibernate, etc., to get the data then wrapping your results into an ObjectArrayDataProvider or whatever.
Good luck.

Similar Messages

  • Java.lang.NoClassDefFoundError: oracle/xml/sql/query/OracleXMLQuery

    Hello, all.
    I get this error message:
    java.lang.NoClassDefFoundError: oracle/xml/sql/query/OracleXMLQuery
    at oracle.xml.xsql.actions.XSQLQueryHandler.handleAction(Compiled Code) ...
    when trying to view an xsql page with the jswdk 1.0.1 web server. (I have no problems when using Web-to-go)
    Classpath includes:
    C:\jdk1.1.8\lib\classes.zip;
    C:\xsql\lib\oraclexsql.jar;
    C:\xsql\lib\xmlparserv2.jar;
    C:\xsql\lib\xsu111.jar;
    C:\xsql\lib\classes111.zip;
    C:\xsql\lib;
    What could be the problem?
    Mateja
    null

    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Steven Muench ([email protected]):
    Only thing I can think of is that maybe your server classpath is getting too long. I recall one of the Java Web Server releases having a classpath length limit that caused strange errors like this because that .jar files you thought were on your classpath were getting their path names truncated so the Java VM cannot find the JAR's.
    Try putting xsu111.jar earlier in the list of JAR's and/or try shortening the classpath (perhaps by using SUBST'd drive letters or softlinks on Unix to shorten the path names).<HR></BLOCKQUOTE>
    Putting the xsu11.jar file towards the start of the path did not help.
    I have rewriten the entire bat file that creates the CLASSPATH and starts the server and things now seem to work. There must have been some error in the original bat file, that I just couldn't see.
    Anyway - I thank you for your help.
    null

  • Strange Long ParNewGC Pauses During Application Startup

    Recently we started seeing long ParNewGC pauses when starting up Kafka that were causing session timeouts:
    [2015-04-24 13:26:23,244] INFO 0 successfully elected as leader (kafka.server.ZookeeperLeaderElector)
    2.111: [GC (Allocation Failure) 2.111: [ParNew: 136320K->10236K(153344K), 0.0235777 secs] 648320K->522236K(2080128K), 0.0237092 secs] [Times: user=0.03 sys=0.01, real=0.02 secs]
    2.599: [GC (Allocation Failure) 2.599: [ParNew: 146556K->3201K(153344K), 9.1514626 secs] 658556K->519191K(2080128K), 9.1515757 secs] [Times: user=18.25 sys=0.01, real=9.15 secs]
    [2015-04-24 13:26:33,443] INFO New leader is 0 (kafka.server.ZookeeperLeaderElector$LeaderChangeListener)
    After much investigation I found that the trigger was the allocation of a 500M static object early in the startup code.  It of course makes no sense that a single large static object in Old memory would impact ParNew collections, but, it does seem to.  I have created a bug report, but, it is still under investigation.
    I have reproduced the problem with a simple application on several Linux platforms including an EC2 instance and the following JREs:
    OpenJDK: 6, 7, and 8
    Oracle: 7 and 8
    Oracle 6 does not seem to have an issue.  All the ParNewGC times are small.
    Here is the simple program that demonstrates the issue:
    import java.util.ArrayList;
    public class LongParNewPause {
       static byte[] bigStaticObject;
       public static void main(String[] args) throws Exception {
       int bigObjSize = args.length > 0 ? Integer.parseInt(args[0]) : 524288000;
       int littleObjSize = args.length > 1 ? Integer.parseInt(args[1]) : 100;
       int saveFraction  = args.length > 2 ? Integer.parseInt(args[2]) : 10;
       bigStaticObject = new byte[bigObjSize];
      ArrayList<byte[]> holder = new ArrayList<byte[]>();
       int i = 0;
       while (true) {
       byte[] local = new byte[littleObjSize];
       if (i++ % saveFraction == 0) {
      holder.add(local);
    I run it with the following options:
    -verbose:gc -XX:+PrintGCTimeStamps -XX:+PrintGCDetails -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -Xmx2G -Xms2G
    Note that I have not seen the issue with 1G heaps.  4G heaps exhibit the issue (as do heaps as small as 1.2G)
    Here is the output:
    0.321: [GC (Allocation Failure) 0.321: [ParNew: 272640K->27329K(306688K), 0.0140537 secs] 784640K->539329K(2063104K), 0.0141584 secs] [Times: user=0.05 sys=0.02, real=0.02 secs]
    0.368: [GC (Allocation Failure) 0.368: [ParNew: 299969K->34048K(306688K), 0.7655383 secs] 811969K->572321K(2063104K), 0.7656172 secs] [Times: user=2.89 sys=0.02, real=0.77 secs]
    1.165: [GC (Allocation Failure) 1.165: [ParNew: 306688K->34048K(306688K), 13.8395969 secs] 844961K->599389K(2063104K), 13.8396650 secs] [Times: user=54.38 sys=0.05, real=13.84 secs]
    15.036: [GC (Allocation Failure) 15.036: [ParNew: 306688K->34048K(306688K), 0.0287254 secs] 872029K->628028K(2063104K), 0.0287876 secs] [Times: user=0.08 sys=0.01, real=0.03 secs]
    15.096: [GC (Allocation Failure) 15.096: [ParNew: 306688K->34048K(306688K), 0.0340727 secs] 900668K->657717K(2063104K), 0.0341386 secs] [Times: user=0.09 sys=0.00, real=0.03 secs]
    Even stranger is the fact that the problem seems to be limited to objects in the range of about 480M to 512M.  Specifically:
    [503316465,536870384]
    Values outside this range appear to be OK.  Anyone have any thoughts?  Can you reproduce the issue on your machine?

    I have started a discussion on this issue on the hotspot-gc-dev list:
    Strange Long ParNew GC Pauses (Sample Code Included)
    One of the engineers on that list was able to reproduce the issue and there is some discussion there about what might be going on.  I am a GC novice, but, am of the opinion that there is a bug to be found in the ParNew GC code introduced in Java 7.
    Here is a more frightening example.  The ParNew GCs keeping getting longer and longer - it never stabilized like the previous example I sent did.  I killed the process once the ParNew GC times reached almost 1 minute each.
    Bad Case - 500M Static Object:
    java -verbose:gc -XX:+PrintGCTimeStamps -XX:+PrintGCDetails -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -Xmx6G -Xms6G LongParNewPause $((500*1024*1024)) 100 100
    0.309: [GC0.309: [ParNew: 272640K->3028K(306688K), 0.0287780 secs] 784640K->515028K(6257408K), 0.0288700 secs] [Times: user=0.08 sys=0.01, real=0.03 secs]
    0.372: [GC0.372: [ParNew: 275668K->7062K(306688K), 0.0228070 secs] 787668K->519062K(6257408K), 0.0228580 secs] [Times: user=0.07 sys=0.00, real=0.03 secs]
    0.430: [GC0.430: [ParNew: 279702K->11314K(306688K), 0.0327930 secs] 791702K->523314K(6257408K), 0.0328510 secs] [Times: user=0.08 sys=0.01, real=0.03 secs]
    0.497: [GC0.497: [ParNew: 283954K->15383K(306688K), 0.0336020 secs] 795954K->527383K(6257408K), 0.0336550 secs] [Times: user=0.08 sys=0.00, real=0.03 secs]
    0.565: [GC0.565: [ParNew: 288023K->21006K(306688K), 0.0282110 secs] 800023K->533006K(6257408K), 0.0282740 secs] [Times: user=0.08 sys=0.00, real=0.03 secs]
    0.627: [GC0.627: [ParNew: 293646K->26805K(306688K), 0.0265270 secs] 805646K->538805K(6257408K), 0.0266220 secs] [Times: user=0.07 sys=0.01, real=0.03 secs]
    0.688: [GC0.688: [ParNew: 299445K->20215K(306688K), 1.3657150 secs] 811445K->535105K(6257408K), 1.3657830 secs] [Times: user=3.97 sys=0.01, real=1.36 secs]
    2.087: [GC2.087: [ParNew: 292855K->17914K(306688K), 6.6188870 secs] 807745K->535501K(6257408K), 6.6189490 secs] [Times: user=19.71 sys=0.03, real=6.61 secs]
    8.741: [GC8.741: [ParNew: 290554K->17433K(306688K), 14.2495190 secs] 808141K->537744K(6257408K), 14.2495830 secs] [Times: user=42.34 sys=0.10, real=14.25 secs]
    23.025: [GC23.025: [ParNew: 290073K->17315K(306688K), 21.1579920 secs] 810384K->540348K(6257408K), 21.1580510 secs] [Times: user=70.10 sys=0.08, real=21.16 secs]
    44.216: [GC44.216: [ParNew: 289955K->17758K(306688K), 27.6932380 secs] 812988K->543511K(6257408K), 27.6933060 secs] [Times: user=103.91 sys=0.16, real=27.69 secs]
    71.941: [GC71.941: [ParNew: 290398K->17745K(306688K), 35.1077720 secs] 816151K->546225K(6257408K), 35.1078600 secs] [Times: user=130.86 sys=0.10, real=35.11 secs]
    107.081: [GC107.081: [ParNew: 290385K->21826K(306688K), 41.4425020 secs] 818865K->553022K(6257408K), 41.4425720 secs] [Times: user=158.25 sys=0.31, real=41.44 secs]
    148.555: [GC148.555: [ParNew: 294466K->21834K(306688K), 45.9826660 secs] 825662K->555757K(6257408K), 45.9827260 secs] [Times: user=180.91 sys=0.14, real=45.98 secs]
    194.570: [GC194.570: [ParNew: 294474K->21836K(306688K), 51.5779770 secs] 828397K->558485K(6257408K), 51.5780450 secs] [Times: user=204.05 sys=0.20, real=51.58 secs]
    246.180: [GC246.180: [ParNew^C: 294476K->18454K(306688K), 58.9307800 secs] 831125K->557829K(6257408K), 58.9308660 secs] [Times: user=232.31 sys=0.23, real=58.93 secs]
    Heap
      par new generation   total 306688K, used 40308K [0x000000067ae00000, 0x000000068fac0000, 0x000000068fac0000)
       eden space 272640K,   8% used [0x000000067ae00000, 0x000000067c357980, 0x000000068b840000)
       from space 34048K,  54% used [0x000000068b840000, 0x000000068ca458f8, 0x000000068d980000)
       to   space 34048K,   0% used [0x000000068d980000, 0x000000068d980000, 0x000000068fac0000)
      concurrent mark-sweep generation total 5950720K, used 539375K [0x000000068fac0000, 0x00000007fae00000, 0x00000007fae00000)
      concurrent-mark-sweep perm gen total 21248K, used 2435K [0x00000007fae00000, 0x00000007fc2c0000, 0x0000000800000000)
    Good Case - 479M Static Object:
    java -verbose:gc -XX:+PrintGCTimeStamps -XX:+PrintGCDetails -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -Xmx6G -Xms6G LongParNewPause $((479*1024*1024)) 100 100
    0.298: [GC0.298: [ParNew: 272640K->3036K(306688K), 0.0152390 secs] 763136K->493532K(6257408K), 0.0153450 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    0.346: [GC0.346: [ParNew: 275676K->7769K(306688K), 0.0193840 secs] 766172K->498265K(6257408K), 0.0194570 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    0.398: [GC0.398: [ParNew: 280409K->11314K(306688K), 0.0203460 secs] 770905K->501810K(6257408K), 0.0204080 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    0.450: [GC0.450: [ParNew: 283954K->17306K(306688K), 0.0222390 secs] 774450K->507802K(6257408K), 0.0223070 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    0.504: [GC0.504: [ParNew: 289946K->18380K(306688K), 0.0169000 secs] 780442K->508876K(6257408K), 0.0169630 secs] [Times: user=0.07 sys=0.01, real=0.02 secs]
    0.552: [GC0.552: [ParNew: 291020K->26805K(306688K), 0.0203990 secs] 781516K->517301K(6257408K), 0.0204620 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    0.604: [GC0.604: [ParNew: 299445K->21153K(306688K), 0.0230980 secs] 789941K->514539K(6257408K), 0.0231610 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    0.659: [GC0.659: [ParNew: 293793K->29415K(306688K), 0.0170240 secs] 787179K->525498K(6257408K), 0.0170970 secs] [Times: user=0.07 sys=0.01, real=0.02 secs]
    0.708: [GC0.708: [ParNew: 302055K->23874K(306688K), 0.0202970 secs] 798138K->522681K(6257408K), 0.0203600 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    0.759: [GC0.760: [ParNew: 296514K->26842K(306688K), 0.0238600 secs] 795321K->528371K(6257408K), 0.0239390 secs] [Times: user=0.07 sys=0.00, real=0.03 secs]
    0.815: [GC0.815: [ParNew: 299482K->25343K(306688K), 0.0237580 secs] 801011K->529592K(6257408K), 0.0238030 secs] [Times: user=0.06 sys=0.01, real=0.02 secs]
    0.870: [GC0.870: [ParNew: 297983K->25767K(306688K), 0.0195800 secs] 802232K->532743K(6257408K), 0.0196290 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    0.921: [GC0.921: [ParNew: 298407K->21795K(306688K), 0.0196310 secs] 805383K->531488K(6257408K), 0.0196960 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    0.972: [GC0.972: [ParNew: 294435K->25910K(306688K), 0.0242780 secs] 804128K->538329K(6257408K), 0.0243440 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    1.028: [GC1.028: [ParNew: 298550K->21834K(306688K), 0.0235000 secs] 810969K->536979K(6257408K), 0.0235600 secs] [Times: user=0.06 sys=0.00, real=0.03 secs]
    1.083: [GC1.083: [ParNew: 294474K->26625K(306688K), 0.0188330 secs] 809619K->544497K(6257408K), 0.0188950 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    1.133: [GC1.133: [ParNew: 299265K->26602K(306688K), 0.0210780 secs] 817137K->547186K(6257408K), 0.0211380 secs] [Times: user=0.06 sys=0.00, real=0.02 secs]
    1.185: [GC1.185: [ParNew: 299242K->26612K(306688K), 0.0236720 secs] 819826K->549922K(6257408K), 0.0237230 secs] [Times: user=0.07 sys=0.00, real=0.03 secs]
    1.240: [GC1.241: [ParNew: 299252K->26615K(306688K), 0.0188560 secs] 822562K->552651K(6257408K), 0.0189150 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    1.291: [GC1.291: [ParNew: 299255K->26615K(306688K), 0.0195090 secs] 825291K->555378K(6257408K), 0.0195870 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    1.342: [GC1.342: [ParNew: 299255K->22531K(306688K), 0.0229010 secs] 828018K->554021K(6257408K), 0.0229610 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    1.396: [GC1.396: [ParNew: 295171K->24505K(306688K), 0.0265920 secs] 826661K->560810K(6257408K), 0.0266360 secs] [Times: user=0.07 sys=0.00, real=0.03 secs]
    1.453: [GC1.453: [ParNew: 297145K->24529K(306688K), 0.0296490 secs] 833450K->563560K(6257408K), 0.0297070 secs] [Times: user=0.09 sys=0.00, real=0.03 secs]
    1.514: [GC1.514: [ParNew: 297169K->27700K(306688K), 0.0259820 secs] 836200K->569458K(6257408K), 0.0260310 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    1.571: [GC1.572: [ParNew: 300340K->27666K(306688K), 0.0199210 secs] 842098K->572150K(6257408K), 0.0199650 secs] [Times: user=0.07 sys=0.01, real=0.02 secs]
    1.623: [GC1.623: [ParNew: 300306K->27658K(306688K), 0.0237020 secs] 844790K->574868K(6257408K), 0.0237630 secs] [Times: user=0.08 sys=0.00, real=0.02 secs]
    1.678: [GC1.678: [ParNew: 300298K->31737K(306688K), 0.0237820 secs] 847508K->581674K(6257408K), 0.0238530 secs] [Times: user=0.08 sys=0.00, real=0.03 secs]
    1.733: [GC1.733: [ParNew: 304377K->21022K(306688K), 0.0265400 secs] 854314K->573685K(6257408K), 0.0265980 secs] [Times: user=0.08 sys=0.00, real=0.02 secs]
    1.791: [GC1.791: [ParNew: 293662K->25359K(306688K), 0.0249520 secs] 846325K->580748K(6257408K), 0.0250050 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    1.847: [GC1.847: [ParNew: 297999K->19930K(306688K), 0.0195120 secs] 853388K->581179K(6257408K), 0.0195650 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    1.898: [GC1.898: [ParNew: 292570K->20318K(306688K), 0.0233960 secs] 853819K->584294K(6257408K), 0.0234650 secs] [Times: user=0.07 sys=0.00, real=0.03 secs]
    1.953: [GC1.953: [ParNew: 292958K->20415K(306688K), 0.0233530 secs] 856934K->587117K(6257408K), 0.0234130 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
    2.007: [GC2.007: [ParNew: 293055K->20439K(306688K), 0.0301410 secs] 859757K->589868K(6257408K), 0.0302070 secs] [Times: user=0.09 sys=0.00, real=0.03 secs]
    2.068: [GC2.068: [ParNew: 293079K->20445K(306688K), 0.0289190 secs] 862508K->592600K(6257408K), 0.0289690 secs] [Times: user=0.09 sys=0.00, real=0.03 secs]
    ^C2.129: [GC2.129: [ParNew: 293085K->29284K(306688K), 0.0218880 secs] 865240K->604166K(6257408K), 0.0219350 secs] [Times: user=0.09 sys=0.00, real=0.02 secs]
    Heap
      par new generation   total 306688K, used 40135K [0x000000067ae00000, 0x000000068fac0000, 0x000000068fac0000)
       eden space 272640K,   3% used [0x000000067ae00000, 0x000000067b898a78, 0x000000068b840000)
       from space 34048K,  86% used [0x000000068d980000, 0x000000068f619320, 0x000000068fac0000)
       to   space 34048K,   0% used [0x000000068b840000, 0x000000068b840000, 0x000000068d980000)
      concurrent mark-sweep generation total 5950720K, used 574881K [0x000000068fac0000, 0x00000007fae00000, 0x00000007fae00000)
      concurrent-mark-sweep perm gen total 21248K, used 2435K [0x00000007fae00000, 0x00000007fc2c0000, 0x0000000800000000)

  • Oracle Text contain query limit with 9i

    The Oracle Text contain query is defined as this:
    CONTAINS(
    [schema.]column,
    text_query VARCHAR2
    [,label NUMBER])
    RETURN NUMBER;
    Is the size limit of text_query 4000 bytes with 9i? Is it increased with 10g or is it accepting CLOB in 10g?
    I always got the error: "ORA-01460: unimplemented or unreasonable conversion requested" when I do the following where p_var was dynamically passed with size of more than 4000 bytes:
    p_statement varchar2(20000);
    p_var varchar2(8000);
    p_statement := select count(*) from dewey_table where contains(concat, :x)>0;
    open m_cursor for p_statement using p_var;
    Thanks very much,
    Kevin

    The limit is definitely 4000 characters in 9i and the 10g documentation shows no change in the calling spec for that parameter.

  • Oracle date parameter query not working?

    http://stackoverflow.com/questions/14539489/oracle-date-parameter-query-not-working
    Trying to run the below query, but always fails even though the parameter values matches. I'm thinking there is a precision issue for :xRowVersion_prev parameter. I want too keep as much precision as possible.
    Delete
    from CONCURRENCYTESTITEMS
    where ITEMID = :xItemId
    and ROWVERSION = :xRowVersion_prev
    The Oracle Rowversion is a TimestampLTZ and so is the oracle parameter type.
    The same code & query works in Sql Server, but not Oracle.
    Public Function CreateConnection() As IDbConnection
    Dim sl As New SettingsLoader
    Dim cs As String = sl.ObtainConnectionString
    Dim cn As OracleConnection = New OracleConnection(cs)
    cn.Open()
    Return cn
    End Function
    Public Function CreateCommand(connection As IDbConnection) As IDbCommand
    Dim cmd As OracleCommand = DirectCast(connection.CreateCommand, OracleCommand)
    cmd.BindByName = True
    Return cmd
    End Function
    <TestMethod()>
    <TestCategory("Oracle")> _
    Public Sub Test_POC_Delete()
    Dim connection As IDbConnection = CreateConnection()
    Dim rowver As DateTime = DateTime.Now
    Dim id As Decimal
    Using cmd As IDbCommand = CreateCommand(connection)
    cmd.CommandText = "insert into CONCURRENCYTESTITEMS values(SEQ_CONCURRENCYTESTITEMS.nextval,'bla bla bla',:xRowVersion) returning ITEMID into :myOutputParameter"
    Dim p As OracleParameter = New OracleParameter
    p.Direction = ParameterDirection.ReturnValue
    p.DbType = DbType.Decimal
    p.ParameterName = "myOutputParameter"
    cmd.Parameters.Add(p)
    Dim v As OracleParameter = New OracleParameter
    v.Direction = ParameterDirection.Input
    v.OracleDbType = OracleDbType.TimeStampLTZ
    v.ParameterName = "xRowVersion"
    v.Value = rowver
    cmd.Parameters.Add(v)
    cmd.ExecuteNonQuery()
    id = CType(p.Value, Decimal)
    End Using
    Using cmd As IDbCommand = m_DBTypesFactory.CreateCommand(connection)
    cmd.CommandText = " Delete from CONCURRENCYTESTITEMS where ITEMID = :xItemId and ROWVERSION = :xRowVersion_prev"
    Dim p As OracleParameter = New OracleParameter
    p.Direction = ParameterDirection.Input
    p.DbType = DbType.Decimal
    p.ParameterName = "xItemId"
    p.Value = id
    cmd.Parameters.Add(p)
    Dim v As OracleParameter = New OracleParameter
    v.Direction = ParameterDirection.Input
    v.OracleDbType = OracleDbType.TimeStampLTZ
    v.ParameterName = "xRowVersion_prev"
    v.Value = rowver
    v.Precision = 6 '????
    cmd.Parameters.Add(v)
    Dim cnt As Integer = cmd.ExecuteNonQuery()
    If cnt = 0 Then Assert.Fail() 'should delete
    End Using
    connection.Close()
    End Sub
    Schema:
    -- ****** Object: Table SYSTEM.CONCURRENCYTESTITEMS Script Date: 1/26/2013 11:56:50 AM ******
    CREATE TABLE "CONCURRENCYTESTITEMS" (
    "ITEMID" NUMBER(19,0) NOT NULL,
    "NOTES" NCHAR(200) NOT NULL,
    "ROWVERSION" TIMESTAMP(6) WITH LOCAL TIME ZONE NOT NULL)
    STORAGE (
    NEXT 1048576 )
    Sequence:
    -- ****** Object: Sequence SYSTEM.SEQ_CONCURRENCYTESTITEMS Script Date: 1/26/2013 12:12:48 PM ******
    CREATE SEQUENCE "SEQ_CONCURRENCYTESTITEMS"
    START WITH 1
    CACHE 20
    MAXVALUE 9999999999999999999999999999

    still not comming...
    i have one table each entry is having only one fromdata and one todate only
    i am running below in sql it is showing two rows. ok.
      select t1.U_frmdate,t1.U_todate  ,ISNULL(t2.firstName,'')+ ',' +ISNULL(t2.middleName ,'')+','+ISNULL(t2.lastName,'') AS NAME, T2.empID  AS EMPID, T2.U_emp AS Empticket,t2.U_PFAcc,t0.U_pf 
       from  [@PR_PRCSAL1] t0 inner join [@PR_OPRCSAL] t1
       on t0.DocEntry = t1.DocEntry
       inner join ohem t2
       on t2.empID = t0.U_empid  where  t0.U_empid between  '830' and  '850'  and t1.U_frmdate ='20160801'  and  t1.u_todate='20160830'
    in commond promt
      select t1.U_frmdate,t1.U_todate  ,ISNULL(t2.firstName,'')+ ',' +ISNULL(t2.middleName ,'')+','+ISNULL(t2.lastName,'') AS NAME, T2.empID  AS EMPID, T2.U_emp AS Empticket,t2.U_PFAcc,t0.U_pf 
       from  [@PR_PRCSAL1] t0 inner join [@PR_OPRCSAL] t1
       on t0.DocEntry = t1.DocEntry
       inner join ohem t2
       on t2.empID = t0.U_empid  where  t0.U_empid between  {?FromEmid} and  {?ToEmid} and t1.U_frmdate ={?FDate} and  t1.u_todate={?TDate}
    still not showing any results..

  • How to tune the performance of Oracle SQL/XML query?

    Hi all,
    I am running Oracle 9i and like to run the following Oracle SQL/XML query. It takes about 3+ hour and still not finish. If I get rid all the XML stuffs it only take minutes to run. Does anybody know how to what's the reason of this slow and how to tune it?
    SELECT XMLElement("CUSTOMER",
    XMLForest(C_CUSTKEY "C_CUSTKEY", C_NAME "C_NAME", C_ADDRESS "C_ADDRESS", C_PHONE "C_PHONE", C_MKTSEGMENT "C_MKTSEGMENT", C_COMMENT "C_COMMENT"),
    (SELECT XMLAgg(XMLElement("ORDERS",
    XMLForest(O_ORDERKEY "O_ORDERKEY", O_CUSTKEY "O_CUSTKEY", O_ORDERSTATUS "O_ORDERSTATUS", O_ORDERPRIORITY "O_ORDERPRIORITY", O_CLERK "O_CLERK", O_COMMENT "O_COMMENT"),
    (SELECT XMLAgg(XMLElement("LINEITEM",
    XMLForest(L_ORDERKEY "L_ORDERKEY", L_RETURNFLAG "L_RETURNFLAG", L_LINESTATUS "L_LINESTATUS", L_SHIPINSTRUCT "L_SHIPINSTRUCT", L_SHIPMODE "L_SHIPMODE", L_COMMENT "L_COMMENT")
    FROM LINEITEM
    WHERE LINEITEM.L_ORDERKEY = ORDERS.O_ORDERKEY)
    FROM ORDERS
    WHERE ORDERS.O_CUSTKEY = CUSTOMER.C_CUSTKEY)
    FROM CUSTOMER ;
    Thanks very much in advance for your time,
    Jinghao Liu

    ajallen wrote:
    Why not something more like
    SELECT *
    FROM fact1 l,
    FULL OUTER JOIN fact1 d
    ON l.company = d.company
    AND l.transactiontypeid = 1
    AND d.transactiontypeid = 2;
    Because this is not an equivalent of the original query.
    drop table t1 cascade constraints purge;
    drop table t2 cascade constraints purge;
    create table t1 as select rownum t1_id from dual connect by level <= 5;
    create table t2 as select rownum+2 t2_id from dual connect by level <= 5;
    select * from (select * from t1 where t1_id > 2) t1 full outer join t2 on (t1_id = t2_id);
    select * from t1 full outer join t2 on (t1_id = t2_id and t1_id > 2);
         T1_ID      T2_ID
             3          3
             4          4
             5          5
                        6
                        7
         T1_ID      T2_ID
             1
             2
             3          3
             4          4
             5          5
                        6
                        7

  • How to perf tune Oracle SQL/XML query?

    Hi all,
    I am using Oracle 9i and like to run the following Oracle SQL/XML query. It takes about 3+ hour and still not finish. If I get rid all the XML stuffs it only take minutes to run. Does anybody know how to what's the reason of this slow and how to tune it?
    SELECT XMLElement("CUSTOMER",
    XMLForest(C_CUSTKEY "C_CUSTKEY", C_NAME "C_NAME", C_ADDRESS "C_ADDRESS", C_PHONE "C_PHONE", C_MKTSEGMENT "C_MKTSEGMENT", C_COMMENT "C_COMMENT"),
    (SELECT XMLAgg(XMLElement("ORDERS",
    XMLForest(O_ORDERKEY "O_ORDERKEY", O_CUSTKEY "O_CUSTKEY", O_ORDERSTATUS "O_ORDERSTATUS", O_ORDERPRIORITY "O_ORDERPRIORITY", O_CLERK "O_CLERK", O_COMMENT "O_COMMENT"),
    (SELECT XMLAgg(XMLElement("LINEITEM",
    XMLForest(L_ORDERKEY "L_ORDERKEY", L_RETURNFLAG "L_RETURNFLAG", L_LINESTATUS "L_LINESTATUS", L_SHIPINSTRUCT "L_SHIPINSTRUCT", L_SHIPMODE "L_SHIPMODE", L_COMMENT "L_COMMENT")
    FROM LINEITEM
    WHERE LINEITEM.L_ORDERKEY = ORDERS.O_ORDERKEY)
    FROM ORDERS
    WHERE ORDERS.O_CUSTKEY = CUSTOMER.C_CUSTKEY)
    FROM CUSTOMER ;
    Thanks very much in advance for your time,
    Jinghao Liu

    Please post this message at:
    Forums Home » Oracle Technology Network (OTN) » Products » Database » XML DB

  • Long Query Runtime/Web-template Loading time

    Hi,
    We are having a very critical performance issue, i.e. long query runtime, which is certainly not acceptable by client as well.
    <b>Background Information</b>
    We are using web application designer (WAD) 2004s release to design front end of our reports built in BI 7.0 system.
    <b>Problem Area</b>
    Loading of web template on browser
    <b>Problem Analysis</b>
    Query taking so long time to run, whenever we load it through portal or even directly through web application designer. Current runtime for query is more than a min. And I have noticed that 95% of runtime is taken for loading variable screen. FYI – if I run query through Query Designer or BEx Analyzer, it takes 3-5 seconds to execute.
    We have taken all the statistics and everything proves that query is not taking any time to execute but it’s the loading time which creates bottle neck.
    <b>Possible Cause</b>
    Web template holding 11 data providers, 5 of which are based on queries and rest are on query views. These data providers load into memory in parallel which could cause delay.
    These data providers expose detailed variable screens. Out of 21 input fields, exposed by web template, 8 fields are based on hierarchy node variables and 1 on hierarchy variable. And to my knowledge each time hierarchy/hierarchy node variable loads complete hierarchy into memory whenever they are called (in other words, its not performance efficient to use hierarchies).
    I request you to please consider this as matter of high priority and provide me with suggestions to remove bottle necks and make the application performance efficient. Please let me know, if you need any further information.
    Thanks.
    Shabbar

    I would recommend you see how long the query execution actually takes without running from the web template. If actually the individual query takes long time then you need to do some performance improvement on back-end side (aggregates, indexing,... and so on).
    But the performance issue is only with web templates, then you need to find some notes on it, because, I remember we had to apply some notes in relations  of browser taking too long time to load the selection screen in web reports.
    After exhausting all the option, then I will implement precalculating the query result before hand using broadcaster.
    thanks.
    Wond

  • Oracle XSU: oracle.xml.sql.query.OracleXMLQuery is not recognized

    Hi, there!
    I've got a problem when tryed to use Oracle XSU (xml-sql utility to generate xml). My simple java application works fine using XSU. But when I created session stateless bean I've got an EJBException regarding this
    line:
    oracle.xml.sql.query.OracleXMLQuery qry = new oracle.xml.sql.query.OracleXMLQuery(conn, commandSQLStatement);
    It doesn't recognize OracleXMLQuery class as I've got in dump. So my classpath includes original location of that utility and Oracle parser.
    I really appreciate for any help.
    Thanks.
    strXML = qry.getXMLString();

    Patricia,
    Did you go through the link
    Re: XML SQL Utility
    You have to put xsu12.jar in the lib directory of the jdev.
    xsu12.jar is in the lib directory of the XDK installation.
    You can download XDK from
    http://www.oracle.com/technology/tech/xml/xdk/software/prod/xdk_java.html
    Just download the XDK kit, get the xsu12.jar from the lib directory and put in the lib directory of the jdev.
    -- Arvind

  • Oracle.xml.sql.query.OracleXMLQuery   GetXML -withDTD

    I'm trying to create a dtd for each table in my schema. I've created a java program that loops through the user_tables and I am then trying to create the DTD with oracle.xml.sql.query.OracleXMLQuery -withDTD. I am able to make it work using the XSU Command Line Utility, but I'm having a hard time trying to find out where the -withDTD flag goes inside my java program. Anyone know how to use the -withDTD option inside of a java program?
    Thanks

    [from XmlRpc-Java]
    As a result, my XML
    is contained in a String instead of an InputStream.
    It is possible to convert a String to an InputStream using
    StringBufferInputStream, but this class is deprecated in favor of
    StringReader (as StringBufferInputStream does not properly convert
    characters into bytes).
    For the default HTTP transport, an InputStreamReader could be used to
    wrap the InputStream before calling parse().
    Ultimately, the InputStream is converted to an InputSource for use by
    the SAX parser. InputSource will accept a Reader as well.
    [from XmlRpc-Java]
    There should be a way to go from "getXMLString()" to "parse(Reader)" also. In the meantime I'm stuck.
    null

  • Oracle.xml.sql.query.OracleXMLQuery not found

    Hi!
    Sorry, but I got a project to continue and there is an import statement "import oracle.xml.sql.query.OracleXMLQuery;" and this gives me a compilation error...
    What do I need to do, where do I find this class??? Any help?
    //Patricia

    Patricia,
    Did you go through the link
    Re: XML SQL Utility
    You have to put xsu12.jar in the lib directory of the jdev.
    xsu12.jar is in the lib directory of the XDK installation.
    You can download XDK from
    http://www.oracle.com/technology/tech/xml/xdk/software/prod/xdk_java.html
    Just download the XDK kit, get the xsu12.jar from the lib directory and put in the lib directory of the jdev.
    -- Arvind

  • Oracle.xml.sql.query.OracleXMLQuery?

    Anyone know where I can find a java doc or any method infomation on:
    oracle.xml.sql.query.OracleXMLQuery
    thanks,
    chad.

    [from XmlRpc-Java]
    As a result, my XML
    is contained in a String instead of an InputStream.
    It is possible to convert a String to an InputStream using
    StringBufferInputStream, but this class is deprecated in favor of
    StringReader (as StringBufferInputStream does not properly convert
    characters into bytes).
    For the default HTTP transport, an InputStreamReader could be used to
    wrap the InputStream before calling parse().
    Ultimately, the InputStream is converted to an InputSource for use by
    the SAX parser. InputSource will accept a Reader as well.
    [from XmlRpc-Java]
    There should be a way to go from "getXMLString()" to "parse(Reader)" also. In the meantime I'm stuck.
    null

  • ORACLE 8I EXPORT의 QUERY OPTION 기능

    제품 : ORACLE SERVER
    작성날짜 : 2000-09-19
    Oracle 8i EXPORT의 Query Option 기능
    ====================================
    Oracle 8i에서는 export 작업 수행 시 Query Option을 이용하여 테이블의
    부분적인 추출이 가능하다.
    SQL> select empno, ename, job, sal from emp order by job;
    EMPNO ENAME JOB SAL
    7788 SCOTT ANALYST 3000
    7902 FORD ANALYST 3000
    9999 홍길동 ANALYST 2000
    7369 SMITH CLERK 800
    7876 ADAMS CLERK 1100
    7934 MILLER CLERK 1300
    7900 JAMES CLERK 950
    7566 JONES MANAGER 2975
    7782 CLARK MANAGER 2450
    7698 BLAKE MANAGER 2850
    7839 KING PRESIDENT 5000
    7499 ALLEN SALESMAN 1600
    7654 MARTIN SALESMAN 1250
    7844 TURNER SALESMAN 1500
    7521 WARD SALESMAN 1250
    위와 같이 구성된 EMP 테이블에서 만일 'MANAGER'로 JOB을 가진 사원중 SAL
    컬럼이 2500이상인 레코드를 export하고 싶다면, 다음과 같이 수행하면 된다.
    % exp scott/tiger tables=emp query=\"where job=\'MANAGER\' and sal\>=2500\"
    Export: Release 8.1.5.0.1 - Production on Tue Sep 19 16:14:15 2000
    About to export specified tables via Conventional Path ...
    . . exporting table EMP 2 rows
    exported
    Export terminated successfully without warnings.
    한글 컬럼에 대해서도 동일한 where 조건에 지정이 가능하다.
    % exp scott/tiger tables=emp query=\"where ename like \'홍%\'\"
    V8.1.5 버젼에서 제공되는 Query 옵션의 특징:
    1. 테이블 레벨의 export 명령어에서만 가능하다.
    2. Direct 옵션과 함께 사용될 수 없다.
    3. Nested 테이블을 갖는 테이블에는 적용할 수 없다.
    4. Partition 테이블에 대한 export에도 적용가능하다.
    5. Import 명령에는 적용되지 않는다.

    Thanks Guys,
    I am still a bit lost though...
    It may be simply a matter of me finding Oracle 8i so I can do what I need to do.
    Where can I get Orcale 8i from? Does anybody have it? The oracle site only has a version back to 9.2 I queried with a employee from Oracle University here in Australia, and he suggested asking in the forums.
    Just so you know what I'm trying to do:
    Data Server:
    Running Aix with Oracle 7.14... actually could be 7.41 - I'll check today.
    This system will not be upgraded to any later version of Orcale, because systems are in place, and core systems at our other sites have to be the same. (my project is a local one)
    Web Server:
    Running XP profession with IIS and using ASP (active server pages)
    Currently running Oracle 10g, and ASP code connects to the local database on this machine via an ODBC connection.
    At the moment, I have scripts on the Aix server that dumps data from Oracle 7.x into a .csv file.
    Then, I have scripts that copy those csv files to the XP server, and they are imported to the local Oracle 10g database.
    To display this data on the website, I use ASP via the odbc connection to query the local database on the XP server.
    As said in my previous post, there must be an easier way to do this.
    I need a local database on the XP server too, and am thinking the best way is to downgrade to 8i.
    Can anybody tell me where I can get 8i to try this out? I have been trying to reasearch this for a while now without luck. Any help would be appreciated, and thanks for those who have replied so far.
    -Tom

  • ORA-29540: class oracle/xml/sql/query/OracleXMLStaticQuery does not exist

    I am getting below error when trying to generate xml. Browsing on google did not help me. I would appreciate if someone can provide the solution.
    SQL> select dbms_xmlquery.getxml('select * from dual', 2) from dual;
    ERROR:
    ORA-29540: class oracle/xml/sql/query/OracleXMLStaticQuery does not exist
    ORA-06512: at "SYS.DBMS_XMLQUERY", line 19
    ORA-06512: at "SYS.DBMS_XMLQUERY", line 271
    ORA-06512: at line 1

    Then it is probably not the case that you are affected by the issue described in Metalink document 185857.1, but if I were you I would check it anyway, since it might be the problem.

  • Where is the oracle.xml.sql.query package?

    Hi,
    I have downloaded the xmlparser_v2_0_2_9.zip. I hoped I have everything to compile the example for retrieving XML document with an sql query. However, the jar file is missing the entire package oracle.xml.sql.query which contains for instance the crucial class OracleXMLQuery. Does anyone know where I could get this package - is it part of another download that I have to do, or can I buy it anywhere? Thanks for your help.
    Karel

    It's part of the XML SQL Utility for Java, avialable for download from http://technet.oracle.com/tech/xml

Maybe you are looking for

  • Creation of transport request

    Hey Sap Gurus, Does anybody know, how to create a Customizing transport request ( and it s task) and assign it some entry for a specific view ? I mean I m creating a program which can add/remove massively the entries in view for structural authorizat

  • How to insert a simple page break in an eBook while using pages to make the ePub?

    Hello, I am using pages to make ePubs. I have a problem: if I insert a page break in pages, it is deleted when I convert the file to ePub. So I do not know how to start on a new page without adding a new chapter.... Do you have a solution? best regar

  • My ichat lost it's freaken mind... im ******... please help

    this morning... my computer ran out of battery... so it died. I hook it up to a power source and then my ichat starts up likes it's the first time... with the 'welcome to ichat' ... so i click continue and my buddy list pops up and everything looks f

  • Setting initial default homepage

    I am deploying FF18.0.2 to about 700 workstations, in the past I have been using; Mozilla.cfg, copied to <install_Folder> //Firefox Default Settings // set Firefox Default homepage pref("browser.startup.homepage","http://myhome.pagesite.org"); // dis

  • How do you create a slide show to a wmv vile?

    I use photoshop Elements 7 I have created several slideshows of my granddaughters wedding, I would like to save them as wmv shows on a DVD but I get a message that the wmv file wasn't created. help did not help solve my questions.