Java.sql.SQLException: FATAL ERROR document format: structure 'Statement',
Hi Gurus,
I did JDBC to SRM scenario. In that the incoming message is posted successfull to the SRM server. But in the acknowledgement message is not delivered to the sender. It gives an error message in the RWB. Its states that the field 'ADATE' contains no values. But when i check the XML payload in RWB it shows value in that particular field. the date format in the X and the Database table is correct both are in the same format as yyyy-mm-dd. But still its giving error messge. Help me to resolve this issue.
This is my payload structure
<?xml version="1.0" encoding="UTF-8" ?>
- <ns0:MT_IMT_Prices_Processed_date_time xmlns:ns0="http://nmhg.com/PRMS_SRM_IMT_Prices">
- <Statement>
- <Update action="UPDATE">
<table>NSAICIP</table>
</Update>
- <Access>
<ADATE>2009-03-16</ADATE>
<ATIME>06:50:27</ATIME>
</Access>
- <Key>
<CIPLT>x</CIPLT>
<CIPRD>xxxxxxx</CIPRD>
<CIKEY>xxxxxxxxx</CIKEY>
</Key>
</Statement>
</ns0:MT_IMT_Prices_Processed_date_time>
Regards,
Rama
Hi,
I think the problem in the date format. i dont know how to resolve.
If the Date format is correct....the problem seems to be in the way the Structure is defined for the JDBC side
Your structure:
<?xml version="1.0" encoding="UTF-8" ?>
<ns0:MT_IMT_Prices_Processed_date_time xmlns:ns0="http://nmhg.com/PRMS_SRM_IMT_Prices">
<Statement>
<Update action="UPDATE">
<table>NSAICIP</table>
</Update>
<Access>
<ADATE>2009-03-16</ADATE>
<ATIME>06:50:27</ATIME>
</Access>
<Key>
<CIPLT>x</CIPLT>
<CIPRD>xxxxxxx</CIPRD>
<CIKEY>xxxxxxxxx</CIKEY>
</Key>
</Statement>
</ns0:MT_IMT_Prices_Processed_date_time>
The correct format: (Check for the start and end position of dbTableName tab)
<ns0:MT_IMT_Prices_Processed_date_time xmlns:ns0="http://nmhg.com/PRMS_SRM_IMT_Prices">
<Statement>
<dbTableName action=u201DUPDATEu201D>
<table>NSAICIP</table>
<access>
<ADATE>2009-03-16</ADATE>
<ATIME>06:50:27</ATIME>
</access>
<key>
<CIPLT>x</CIPLT>
<CIPRD>xxxxxxx</CIPRD>
<CIKEY>xxxxxxxxx</CIKEY>
</key>
</dbTableName>
</Statement>
</ns0:MT_IMT_Prices_Processed_date_time>
For more info refer this link:
http://help.sap.com/saphelp_nw04/helpdata/en/2e/96fd3f2d14e869e10000000a155106/content.htm
As far as possible use the same tab names and the same case for the tab-names (other than table entries) as those mentioned in the above link.
Regards,
Abhishek.
Similar Messages
-
FATAL ERROR document format: structure 'STATEMENT'
Hi experts,
I've a scenario IDOC to JDBC, give me the error: FATAL ERROR document format: structure 'STATEMENT'
I don't understand becausse payload is OK:
<?xml version="1.0" encoding="UTF-8" ?>
- <ns0:MT_MATERIALES xmlns:ns0="http://idom.com/arteche/PP_I07_15A/Maestro_Materiales">
- <STATEMENT>
- <TABLENAME ACTION="UPDATE_INSERT">
<TABLE>MAESTRO_MATERIALES</TABLE>
</TABLENAME>
- <ACCESS>
<MATERIAL>100000016</MATERIAL>
<DESCRIPCION>mmpp1</DESCRIPCION>
<TIPO_ARTICULO>3</TIPO_ARTICULO>
<GRUPO_ARTICULOS>014</GRUPO_ARTICULOS>
<LEADTIME>00</LEADTIME>
<CENTRO>0101</CENTRO>
</ACCESS>
</STATEMENT>
</ns0:MT_MATERIALES>
somebody can help me please?
very thanks,Hi,
The format of your input message (towards DB is not proper)...
<ns0:MT_MATERIALES xmlns:ns0="http://idom.com/arteche/PP_I07_15A/Maestro_Materiales">
- <STATEMENT>
<TABLENAME ACTION="UPDATE_INSERT">
<TABLE>MAESTRO_MATERIALES</TABLE>
</TABLENAME>
<ACCESS>
<MATERIAL>100000016</MATERIAL>
<DESCRIPCION>mmpp1</DESCRIPCION>
<TIPO_ARTICULO>3</TIPO_ARTICULO>
<GRUPO_ARTICULOS>014</GRUPO_ARTICULOS>
<LEADTIME>00</LEADTIME>
<CENTRO>0101</CENTRO>
</ACCESS>
</STATEMENT>
</ns0:MT_MATERIALES>
The actual format should be:
<root>
<StatementName1>
<dbTableName action=u201DUPDATEu201D | u201CUPDATE_INSERTu201D>
<table>realDbTableName</table>
<access>
<col1>val1</col1>
<col2>val2new</col2>
</access>
<key1>
<col2>val2old</col2>
<col4>val4</col4>
</key1>
<key2>
<col2>val2old2</col2>
</key2>
</dbTableName>
</StatementName1>
In the above format look where the TableName tab should end...for more info:
http://help.sap.com/saphelp_nw04/helpdata/en/2e/96fd3f2d14e869e10000000a155106/content.htm
Regards,
Abhishek
Edited by: abhishek salvi on Feb 26, 2009 4:07 PM -
Java.sql.SQLException: FATAL ERROR for DB2
Hi
In my scenario IDOC-XI-DB2,
When I am getting following error message in communication channel. I have checked all the field length, they are correctly displayed. Please let me know how to resolve the same.
Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'BI5FILMM.BSOMSAPP' (structure 'StatementInsert'): java.sql.SQLException: FATAL ERROR document format in structure 'StatementInsert': expected 'access' tag(s) not found
Payload is as follows
<?xml version="1.0" encoding="UTF-8" ?>
- <I805_Abstr_CustOutlet_MT>
- <StatementInsert>
- <STATUS action="INSERT">
<table>BI5FILMM.BSOMSAPP</table>
<key OUTLET_NO="0001231229" OUTLET_RF="0002122756" OMFUNC="CRT" />
- <access>
<STATUS>N</STATUS>
<IFCEDATE>1080701</IFCEDATE>
<IFCETIME>160849</IFCETIME>
<OUTLETTYPE>Y</OUTLETTYPE>
<NAME>DREW SMITH AGAINXXXXXXXXXXXXXXXXXXX</NAME>
<STREET>E</STREET>
<STATE>NSW</STATE>
<POST_CODE>2000</POST_CODE>
<PHONE_NO>567999</PHONE_NO>
<ALTPHONE>11111</ALTPHONE>
<FAX_NO>111</FAX_NO>
<CNTCT_PERS>Constant</CNTCT_PERS>
<ALTNAME>Constant</ALTNAME>
<EMAIL1>Drew_downunder</EMAIL1>
<EMAIL2>DREW_DOWNUNDER</EMAIL2>
<SFE_CODE>G</SFE_CODE>
<BILL_TO>0001231229</BILL_TO>
<SUPP_DATE>080801</SUPP_DATE>
</access>
</STATUS>
</StatementInsert>
- <StatementProce>
- <STATUS action="EXECUTE">
<table>CC5PTF.BSOMPSAP</table>
<Para1 isInput="true" type="CHAR">BI5FILMM</Para1>
<Para2 isInput="true" type="CHAR">BMIJOBD</Para2>
</STATUS>
</StatementProce>
</I805_Abstr_CustOutlet_MT>Hi Ria,
In your input try to make the access tag in capitals(ACCESS) and try. I am not sure though. I think its case sensitive. Just try and let me know. Also your second action="EXECUTE" does not has any access parameters. Refer to this blog:
JDBC Receiver Adapter -- Synchronous Select Step by Step
It might be useful.
Regards,
Sanjeev. -
JDBC Receiver: FATAL ERROR document format: invalid level 4
Hi,
I am creating an IDOC -JDBC scenario .
The XML created has action as delete.
but in the comminication channel i am getting an error which is
Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'T_SAP_WBS' (structure 'statement1'): java.sql.SQLException: FATAL ERROR document format: invalid level 4' found (structure 'statement1')
does any one have any idea on this?
Regards,
Tarun BahalHi,
The JDBC format which you are using is incorrect.....please maintain the format as mentioned in this document...there seems to be some mismatch
http://help.sap.com/saphelp_nw04/helpdata/en/2e/96fd3f2d14e869e10000000a155106/content.htm
By maintaining the format i mean:
1) maintain the hierarchy as mentioned in the link
2) maintain the case (upper/ lower) for the standard elements (you seem to be using statement1 instead of Statement)
3) If there are no multiple stattements then have the name as Statement
If still facing the problem....provide your structure in sdn
Regards,
Abhishek. -
I am getting Error! java.sql.SQLException:General error
hi every body,
I struck with this error , can any one suggest in solving this.
I had a table in oracledatabase ,i have successfully created a table and inserted clob column with an attachment like xxx.txt.
table format----> id and text columns
Now my question is to retrieve that data and store it in local disk i am getting this error
import java.io.*;
import java.sql.*;
//import java.sql.SQLException;
public class Cread {
public static void main(String[] args) throws ClassNotFoundException,IOException,SQLException {
try {
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection cn=DriverManager.getConnection("jdbc:odbc:sivadsn","scott","tiger");
Statement s = cn.createStatement();
ResultSet rs=s.executeQuery("Select text from ram where id=10");
if(rs.next()){
FileOutputStream file=new FileOutputStream("c:/store.txt");
InputStream fin=rs.getBinaryStream(1);
int c;
while((c=fin.read())!=-1){
file.write(c);
fin.close();
s.close();
rs.close();
catch(IOException e){
e.printStackTrace();
System.out.println("Err:"+e);
I am getting the error as
java.sql.SQLException: General error
at sun.jdbc.odbc.JdbcOdbc.createSQLException(Unknown Source)
at sun.jdbc.odbc.JdbcOdbc.standardError(Unknown Source)
at sun.jdbc.odbc.JdbcOdbc.SQLExecDirect(Unknown Source)
at sun.jdbc.odbc.JdbcOdbcStatement.execute(Unknown Source)
at sun.jdbc.odbc.JdbcOdbcStatement.executeQuery(Unknown Source)Error! java.sql.SQLException: General error
at attach.Clobread.main(Clobread.java:30)That usually means something is wrong with the syntax of your sql.
As a guess 'text' is probably a keyword and shouldn't be used as a field name. It is possible that the same is true for 'id' -
Hello all,
I am getting this following error , when trying to load from files to Oracle (used this link as reference : http://john-goodwin.blogspot.com/2009/06/odi-series-processing-all-files-in.html)
ODI 11g 11.1.1.6
Database
Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
PL/SQL Release 11.2.0.2.0 - Production
CORE 11.2.0.2.0 Production
TNS for Linux: Version 11.2.0.2.0 - Production
NLSRTL Version 11.2.0.2.0 - Production
any help would be greatly appreciated
7000 : null : java.sql.SQLException: ODI-40400: Invalid format description
java.sql.SQLException: ODI-40400: Invalid format description
at com.sunopsis.jdbc.driver.file.impl.metadata.MetaDataExtractor.buildTableDescFromRequestSQLExceptionOnly(MetaDataExtractor.java:479)
at com.sunopsis.jdbc.driver.file.FilePreparedStatement.buildGenericRow(FilePreparedStatement.java:75)
at com.sunopsis.jdbc.driver.file.FilePreparedStatement.<init>(FilePreparedStatement.java:57)
at com.sunopsis.jdbc.driver.file.FileConnection.prepareStatement(FileConnection.java:299)
at sun.reflect.GeneratedMethodAccessor67.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at oracle.odi.core.datasource.dwgobject.support.OnConnectOnDisconnectDataSourceAdapter$OnDisconnectCommandExecutionHandler.invoke(OnConnectOnDisconnectDataSourceAdapter.java:200)
at $Proxy2.prepareStatement(Unknown Source)
at oracle.odi.runtime.agent.execution.sql.SQLCommand.doInitializeStatement(SQLCommand.java:82)
at oracle.odi.runtime.agent.execution.sql.SQLCommand.getStatement(SQLCommand.java:117)
at oracle.odi.runtime.agent.execution.sql.SQLCommand.getBatchCommand(SQLCommand.java:329)
at oracle.odi.runtime.agent.execution.sql.SQLCommand.processRecord(SQLCommand.java:137)
at oracle.odi.runtime.agent.execution.cmd.TextCommand.processRecord(TextCommand.java:1)
at oracle.odi.runtime.agent.execution.DataMovementTaskExecutionHandler.handleTask(DataMovementTaskExecutionHandler.java:86)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.processTask(SnpSessTaskSql.java:2913)
at com.sunopsis.dwg.dbobj.SnpSessTaskSql.treatTask(SnpSessTaskSql.java:2625)
at com.sunopsis.dwg.dbobj.SnpSessStep.treatAttachedTasks(SnpSessStep.java:561)
at com.sunopsis.dwg.dbobj.SnpSessStep.treatSessStep(SnpSessStep.java:464)
at com.sunopsis.dwg.dbobj.SnpSession.treatSession(SnpSession.java:2093)
at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$2.doAction(StartSessRequestProcessor.java:366)
at oracle.odi.core.persistence.dwgobject.DwgObjectTemplate.execute(DwgObjectTemplate.java:216)
at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.doProcessStartSessTask(StartSessRequestProcessor.java:300)
at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor.access$0(StartSessRequestProcessor.java:292)
at oracle.odi.runtime.agent.processor.impl.StartSessRequestProcessor$StartSessTask.doExecute(StartSessRequestProcessor.java:855)
at oracle.odi.runtime.agent.processor.task.AgentTask.execute(AgentTask.java:126)
at oracle.odi.runtime.agent.support.DefaultAgentTaskExecutor$2.run(DefaultAgentTaskExecutor.java:83)
at java.lang.Thread.run(Thread.java:662)Question2:
I am calling
OdiStartScen -SCEN_NAME=ALL_FILES -SCEN_VERSION=001 "-ACTIVITIES.CURRFILENAME=#LOADFILE"
in ODI procedure and when I execute I am getting this following error two
OdiStartScen -SCEN_NAME=ALL_FILES -SCEN_VERSION=001 "-ACTIVITIES.CURRFILENAME=#LOADFILE"
Exception getTargetTable("METADATA_DESC") : ODI-15081: There is no Target TableBoth these errors are happening the same procedure with two commandsHello,
I am getting the same error too. I am just trying to load simple (13 columns all number) txt to oracle table. My interface defination doesn't contain any transformation, filter or join.
7000 : null : java.sql.SQLException: ODI-40400: Invalid format description
java.sql.SQLException: ODI-40400: Invalid format description
at com.sunopsis.jdbc.driver.file.impl.metadata.MetaDataExtractor.buildTableDescFromRequestSQLExceptionOnly(MetaDataExtractor.java:479)
at com.sunopsis.jdbc.driver.file.FilePreparedStatement.<init>(FilePreparedStatement.java:62)
at com.sunopsis.jdbc.driver.file.FileConnection.prepareStatement(FileConnection.java:299)
at sun.reflect.GeneratedMethodAccessor66.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at oracle.odi.core.datasource.dwgobject.support.OnConnectOnDisconnectDataSourceAdapter$OnDisconnectCommandExecutionHandler.invoke(OnConnectOnDisconnectDataSourceAdapter.java:200)
Source Code:
select
CITY_ID
C1_CITY_ID,
DISTRICT_ID
C2_DISTRICT_ID,
TOWNSHIP_ID
C3_TOWNSHIP_ID,
VILLAGE_ID
C4_VILLAGE_ID,
QUARTER_ID
C5_QUARTER_ID,
STREET_ID
C6_STREET_ID,
BUILDING_ID
C7_BUILDING_ID,
INDEPENDENTSECTION_ID
C8_INDEPENDENTSECTION_ID,
MATCH_LEVEL
C9_MATCH_LEVEL,
SERIAL_NUM_SEQ
C10_SERIAL_NUM_SEQ,
POLICY_NUM
C11_POLICY_NUM,
RENEWAL_NUM
C12_RENEWAL_NUM,
ADDRESS_NUM
C13_ADDRESS_NUM
from
TABLE
/*$$SNPS_START_KEYSNP$CRDWG_TABLESNP$CRTABLE_NAME=ADDRESS_HINT_FLSNP$CRLOAD_FILE=C:/temi/adress_hints.txtSNP$CRFILE_FORMAT=DSNP$CRFILE_SEP_FIELD=0x0009SNP$CRFILE_SEP_LINE=0x000D0x000ASNP$CRFILE_FIRST_ROW=1SNP$CRFILE_ENC_FIELD=SNP$CRFILE_DEC_SEP=SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=CITY_IDSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=1SNP$CRLINE_OFFSET=1SNP$CRLENGTH=3SNP$CRSCALE=0SNP$CRPRECISION=3SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=DISTRICT_IDSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=2SNP$CRLINE_OFFSET=4SNP$CRLENGTH=5SNP$CRSCALE=0SNP$CRPRECISION=5SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=TOWNSHIP_IDSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=3SNP$CRLINE_OFFSET=9SNP$CRLENGTH=5SNP$CRSCALE=0SNP$CRPRECISION=5SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=VILLAGE_IDSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=4SNP$CRLINE_OFFSET=14SNP$CRLENGTH=10SNP$CRSCALE=0SNP$CRPRECISION=10SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=QUARTER_IDSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=5SNP$CRLINE_OFFSET=24SNP$CRLENGTH=10SNP$CRSCALE=0SNP$CRPRECISION=10SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=STREET_IDSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=6SNP$CRLINE_OFFSET=34SNP$CRLENGTH=10SNP$CRSCALE=0SNP$CRPRECISION=10SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=BUILDING_IDSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=7SNP$CRLINE_OFFSET=44SNP$CRLENGTH=15SNP$CRSCALE=0SNP$CRPRECISION=15SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=INDEPENDENTSECTION_IDSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=8SNP$CRLINE_OFFSET=59SNP$CRLENGTH=15SNP$CRSCALE=0SNP$CRPRECISION=15SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=MATCH_LEVELSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=9SNP$CRLINE_OFFSET=74SNP$CRLENGTH=2SNP$CRSCALE=0SNP$CRPRECISION=2SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=SERIAL_NUM_SEQSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=10SNP$CRLINE_OFFSET=76SNP$CRLENGTH=10SNP$CRSCALE=0SNP$CRPRECISION=10SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=POLICY_NUMSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=11SNP$CRLINE_OFFSET=86SNP$CRLENGTH=10SNP$CRSCALE=0SNP$CRPRECISION=10SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=RENEWAL_NUMSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=12SNP$CRLINE_OFFSET=96SNP$CRLENGTH=2SNP$CRSCALE=0SNP$CRPRECISION=2SNP$CRSNP$CRDWG_COLSNP$CRCOL_NAME=ADDRESS_NUMSNP$CRTYPE_NAME=NUMERICSNP$CRORDER=13SNP$CRLINE_OFFSET=98SNP$CRLENGTH=20SNP$CRSCALE=0SNP$CRPRECISION=20SNP$CR$$SNPS_END_KEY*/
Target Code:
insert into DASK_DWH.C$_0ADDRESS_HINT
C1_CITY_ID,
C2_DISTRICT_ID,
C3_TOWNSHIP_ID,
C4_VILLAGE_ID,
C5_QUARTER_ID,
C6_STREET_ID,
C7_BUILDING_ID,
C8_INDEPENDENTSECTION_ID,
C9_MATCH_LEVEL,
C10_SERIAL_NUM_SEQ,
C11_POLICY_NUM,
C12_RENEWAL_NUM,
C13_ADDRESS_NUM
values
:C1_CITY_ID,
:C2_DISTRICT_ID,
:C3_TOWNSHIP_ID,
:C4_VILLAGE_ID,
:C5_QUARTER_ID,
:C6_STREET_ID,
:C7_BUILDING_ID,
:C8_INDEPENDENTSECTION_ID,
:C9_MATCH_LEVEL,
:C10_SERIAL_NUM_SEQ,
:C11_POLICY_NUM,
:C12_RENEWAL_NUM,
:C13_ADDRESS_NUM -
Hi,
I am getting the following exception when i trying to insert data in to a table through a stored procedure.
oracle.apps.fnd.framework.OAException: java.sql.SQLException: ORA-01801: date format is too long for internal buffer
when execute this stored procedure from ana anonymous block , it gets executed successfully, but i use a OracleCallableStatement to execute the procedure i am getting this error.
Please let me know how to resolve this error.
Is this error something to do with the Database Configuration ?
Thanks & Regards
MeenalI don't know if this will help, but we were getting this error in several of the standard OA framework pages and after much pain and aggravation it was determined that visiting the Sourcing Home Page was changing the timezone. For most pages this just changed the timezone that dates were displayed in, but some had this ORA-01801 error and some others had an ORA-01830 error (date format picture ends before converting entire input string). Unfortunately, if you are not using Sourcing at your site, this probably won't help, but if you are, have a look at patch # 4519817.
Note that to get the same error, try the following query (I got this error in 9.2.0.5 and 10.1.0.3):
select to_date('10-Mar-2006', 'DD-Mon-YYYY________________________________________________HH24:MI:SS') from dual;
It appears that you can't have a date format that is longer than 68 characters. -
Java.sql.SQLException: Internal Error: Inconsistent catalog view
Hi all,
I have an Oracle procedure defined like:
pkgoms.p_oms_audit ( in_tab_oms_audit in tab_oms_audit,out_status out number)
tab_oms_audit is a collection of t_oms_audit
Here is the structure for the type (with 16 fileds)
create or replace type t_oms_audit as object(
Username_ VARCHAR2(101),
d_Date_ Date,
<other fields>) ;
In my Java code I have:
// conn is the connections to db
oracle.sql.StructDescriptor structDesc = oracle.sql.StructDescriptor.createDescriptor("TAB_OMS_AUDIT", conn);
Object[] attributes = new Object[16];
// Fill out the array: attributes[] in the same structure that t_oms_audit is defined
// Receive the following error on the next line:
// java.sql.SQLException: Internal Error: Inconsistent catalog view
oracle.sql.STRUCT struct = new oracle.sql.STRUCT(structDesc, conn, attributes);
anOracleCallableStatement.setObject(1, struct, java.sql.Types.STRUCT);
anOracleCallableStatement.execute();I searched for the above error and the only thing I could find was that its a permission issue; I can execute select, update, insert, delete, ... on db, so not sure if its in fact a permission issue or I am doing sth. else wrong. Any help is greatly appreciated.Hi all
I have the same problem.
it's not a GRANT problem because in PL/SQL the object works fine.
JDBC Release problem?
Any help is greatly appreciated. -
hi...i am tryin to connect to sqlserver2000 ....i wanted a dsnless connection...i have downloaded jtds driver...set the classpath..no joy..i'm connecting to sqlserver's default port 1433..i also confirmed that sqlserver tcp is enabled...still gettin the same err:
java.sql.SQLException: Network error IOException: Connection refused: connect
at net.sourceforge.jtds.jdbc.ConnectionJDBC2.<init>(ConnectionJDBC2.java
:385)
at net.sourceforge.jtds.jdbc.ConnectionJDBC3.<init>(ConnectionJDBC3.java
:50)
at net.sourceforge.jtds.jdbc.Driver.connect(Driver.java:182)
at java.sql.DriverManager.getConnection(DriverManager.java:525)
at java.sql.DriverManager.getConnection(DriverManager.java:171)
at SQLServerConnect.getConnection(SQLServerConnect.java:27)
at SQLServerConnect.displayDbProperties(SQLServerConnect.java:44)
at SQLServerConnect.main(SQLServerConnect.java:80)
Caused by: java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:364)
at java.net.Socket.connect(Socket.java:507)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at net.sourceforge.jtds.jdbc.SharedSocket.createSocketForJDBC3(SharedSoc
ket.java:304)
at net.sourceforge.jtds.jdbc.SharedSocket.<init>(SharedSocket.java:255)
at net.sourceforge.jtds.jdbc.ConnectionJDBC2.<init>(ConnectionJDBC2.java
:310)
... 7 more
Error Trace in getConnection() : Network error IOException: Connection refused:
connect
Error: No active Connection
i even tried connecting to the port 1433 thru telnet...err:Could not open connection to the host, on port 1433:connection failed...
i thought it cud b a firewall issue...disabled my windows firewall..no joy..
can ne body help me with this....need to solve this desparately
thanks in advance
judeOld, but still coming up in google searches. Here's the solution that worked for me:
Dynamic Port Allocation explained:
http://support.microsoft.com/kb/823938
How to: Configure a Server to Listen on a Specific TCP Port (SQL Server Configuration Manager)
http://support.microsoft.com/kb/823938
In case that dissappears:
To assign a TCP/IP port number to the SQL Server Database Engine
1. In SQL Server Configuration Manager, in the console pane, expand SQL Server 2005 Network Configuration, expand Protocols for <instance name>, and then double-click TCP/IP.
2. In the TCP/IP Properties dialog box, on the IP Addresses tab, several IP addresses appear, in the format IP1, IP2, up to IPAll. One of these are for the IP address of the loopback adapter, 127.0.0.1. Additional IP addresses appear for each IP Address on the computer. Right-click each address, and then click Properties to identify the IP address that you wish to configure.
3. If the TCP Dynamic Ports dialog box contains 0, indicating the Database Engine is listening on dynamic ports, delete the 0.
4. In the IPn Properties area box, in the TCP Port box, type the port number you wish this IP address to listen on, and then click OK.
5. In the console pane, click SQL Server 2005 Services.
6. In the details pane, right-click SQL Server (<instance name>) and then click restart, to stop and restart SQL Server. -
Java.sql.SQLException: General error
Hi i got this error message:
java.sql.SQLException: General error
at sun.jdbc.odbc.JdbcOdbc.createSQLException(Unknown Source)
at sun.jdbc.odbc.JdbcOdbc.standardError(Unknown Source)
at sun.jdbc.odbc.JdbcOdbc.SQLExecDirect(Unknown Source)
at sun.jdbc.odbc.JdbcOdbcStatement.execute(Unknown Source)
at sun.jdbc.odbc.JdbcOdbcStatement.executeUpdate(Unknown Source)
at PersonFrame.actionPerformed(PersonFrame.java:1155)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(Unknow
n Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Sour
ce)
at java.awt.Component.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
my code is:
while (rs.next())
String recnumber = rs.getString("Person_ Record_ Number");
int reccc=Integer.parseInt(recnumber);
if (Integer.parseInt(FamilyTree.rowselected)==reccc && AddPersonn!=0)
System.out.println ("record in table "+reccc);
System.out.println ("record selected "+FamilyTree.rowselected);
str.executeUpdate("INSERT INTO Person " +
"VALUES ('"+nameofperson.getText()+"','"+SurnameOfPersonTxt.getText()+"','"+Bday+"','EMPTY','"+DateOfDeathTogether+"','EMPTY','EMPTY','"+phone+"','"+genre+"','"+Country+"','"+FamilyTree.rowselected+"','"+Nicknametxt.getText()+"','"+Filename+"','"+BioFile+"','"+city+"','"+postal+"','EMPTY','empty','"+TimeOfBirth+"','EMPTY')");
setVisible(false);
System.out.println(Filename);
LINE 1155 that the error message says is line :str.executeUpdate("INSERT INTO Person " +
<<<PersonFrame.actionPerformed(PersonFrame.java:1155)>>>>>
also note that i didn't include a try statement here (int reccc=Integer.parseInt(recnumber) because recnumber since is created holds the value 5000 so there is no need
Also the output.. of
System.out.println("INSERT INTO Person " + "VALUES ('"+nameofperson.getText()+"','"+SurnameOfPersonTxt.getText()+"','"+Bday+"','EMPTY','"+DateOfDeathTogether+"','"+PlaceOfDeath+"','"+address+"','"+phone+"','"+genre+"','"+Country+"','"+FamilyTree.rowselected+"','"+Nicknametxt.getText()+"','"+Filename+"','"+BioFile+"','"+city+"','"+postal+"','"+Causeofdeath+"','"+PlaceBurried+"','"+TimeOfBirth+"','EMPTY')");
is:
INSERT INTO Person VALUES ('fgfgff','dfdgfd','2/1/1988','EMPTY','Person Is Alive','null','EMPTY','EMPTY','Male','EMPTY','0560','dasfds','EMPTY','EMPTY','EMPTY','EMPTY','null','null','EMPTY','EMPTY')
and my table gets only text values...
Any Help Will Be Greately Appreciated
Thanks
Nick .sYou cannot do two thing at the same time with the same statement (while your ResultSet is open you are making an insert), try using a separate Statement that the one you used for the query for the insert. If that doesn't work, make a new connection, that will do it.
If you were using a separate statement then I'm sorry, I couldn't tell from your code. I'd had a similar problem and that's the way I solved it. -
I am getting an error when I am coming out of a method. I am not doing any database operations in the code.
The error I am getting is
The activity execution failed.\nCaused by: Activity '/AddNewSubMaster#Default-1.0/DeleteRequests' task 'Confirmation_Router' could not execute successfully.\nCaused by: Process execution engine execution error.\nCaused by: An error occurred while accesing the database.\nTechnical detail:SQL statement: 'unknown'\n\nCaused by: Unexpected exception while enlisting XAConnection java.sql.SQLException: XA error: XAResource.XAER_PROTO start() failed on resource 'ALBPM Engine Database': XAER_PROTO : Routine was invoked in an inproper context\noracle.jdbc.xa.OracleXAException\n\tat oracle.jdbc.xa.OracleXAResource.checkError(OracleXAResource.java:938)\n\tat oracle.jdbc.xa.client.OracleXAResource.start(OracleXAResource.java:244)\n\tat weblogic.jdbc.wrapper.VendorXAResource.start(VendorXAResource.java:50)\n\tat weblogic.jdbc.jta.DataSource.start(DataSource.java:710)\n\tat weblogic.transaction.internal.XAServerResourceInfo.start(XAServerResourceInfo.java:1182)\n\tat ...........Are you using studio?
I see an Oracle DB-connection. In studio without configuration you only have one or two derby databases. -
Java.sql.SQLException: Internal error: Cannot obtain XAConnection
Hi,
I am getting this error .
I have a multi data source which serves two Data source and is using load balancing
I get the below error:
Cannot obtain XAConnection weblogic.common.ResourceException: No good connections available.
The complete error trace is below:
GWMDBBean [onMessage(Message)] 09_MAY 16:24:13:165->EXCEPTION
java.sql.SQLException: Internal error: Cannot obtain XAConnection weblogic.common.ResourceException: No good connections available.
at weblogic.jdbc.common.internal.MultiPool.findPool(MultiPool.java:187)
at weblogic.jdbc.common.internal.ConnectionPoolManager.reserve(ConnectionPoolManager.java:87)
at weblogic.jdbc.common.internal.ConnectionPoolManager.reserve(ConnectionPoolManager.java:61)
at weblogic.jdbc.jta.DataSource.getXAConnectionFromPool(DataSource.java:1514)
at weblogic.jdbc.jta.DataSource.refreshXAConnAndEnlist(DataSource.java:1301)
at weblogic.jdbc.jta.DataSource.getConnection(DataSource.java:426)
at weblogic.jdbc.jta.DataSource.connect(DataSource.java:383)
at weblogic.jdbc.common.internal.RmiDataSource.getConnection(RmiDataSource.java:346)
at com.iflex.fcubs.gwutil.db.GWDBUtil.getConnection(GWDBUtil.java:119)
at com.iflex.fcubs.gwservices.db.GWMsgProcessor.getConnection(GWMsgProcessor.java:95)
at com.iflex.fcubs.gwservices.db.inbound.GWMsgSchemaProc.processMsg(GWMsgSchemaProc.java:165)
at com.iflex.fcubs.gw.mdb.GWMDBBean.processMessage(GWMDBBean.java:1051)
at com.iflex.fcubs.gw.mdb.GWMDBBean.onMessage(GWMDBBean.java:371)
at weblogic.ejb.container.internal.MDListener.execute(MDListener.java:466)
at weblogic.ejb.container.internal.MDListener.transactionalOnMessage(MDListener.java:371)
at weblogic.ejb.container.internal.NewJMSMessagePoller.processOneMessage(NewJMSMessagePoller.java:245)
at weblogic.ejb.container.internal.NewJMSMessagePoller.run(NewJMSMessagePoller.java:121)
at weblogic.ejb.container.internal.NewJMSMessagePoller.timerExpired(NewJMSMessagePoller.java:204)
at weblogic.timers.internal.TimerImpl.run(TimerImpl.java:273)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:516)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
at com.iflex.fcubs.gw.mdb.GWMDBBean.processMessage(GWMDBBean.java:1060)
at com.iflex.fcubs.gw.mdb.GWMDBBean.onMessage(GWMDBBean.java:371)
at weblogic.ejb.container.internal.MDListener.execute(MDListener.java:466)
at weblogic.ejb.container.internal.MDListener.transactionalOnMessage(MDListener.java:371)
at weblogic.ejb.container.internal.NewJMSMessagePoller.processOneMessage(NewJMSMessagePoller.java:245)
at weblogic.ejb.container.internal.NewJMSMessagePoller.run(NewJMSMessagePoller.java:121)
at weblogic.ejb.container.internal.NewJMSMessagePoller.timerExpired(NewJMSMessagePoller.java:204)
at weblogic.timers.internal.TimerImpl.run(TimerImpl.java:273)
at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:516)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
The Data Sources Configuration are as below:
<initial-capacity>15</initial-capacity>
<max-capacity>15</max-capacity>This indicates that none of your datasources have been able to successfully connect to the database.
Please check the connectivity to your database from the datasources.
Also, you can login into the console and check if the connections are good, by doing test connection on the datasource.
http://docs.oracle.com/cd/E21764_01/apirefs.1111/e13952/taskhelp/jdbc/jdbc_datasources/TestDataSources.html
The error you get when you do test connection will help you to understand any connectivity issues.
Arun -
Hi All,
I am facing below issue without any change in the config from weblogic
Managed servers are coming up and running without any issue
But when we are doing any operation from application then its failing
java.sql.SQLException: Unexpected exception while enlisting XAConnection java.sql.SQLException: XA error: XAResource.XAER_RMFAIL start() failed on resource 'myDomain': XAER_RMFAIL : Resource manager is unavailable
Regards
LokeshHi,
Can you please try increase the below MaxXACallMillis setting in Weblogic set 'Maximum Duration of XA Calls' to a bigger value
MaxXACallMillis: Sets the maximum allowed duration (in milliseconds) of XA calls to XA resources. This setting applies to the entire domain.
http://docs.oracle.com/cd/E12840_01/wls/docs103/jta/trxcon.html
The parameter is exposed through administration console: services --> jta --> advanced --> "Maximum Duration of XA Calls:"
Check the below docs for more information
WLS 10.3: Intermittent XA error: XAResource.XAER_RMERR (Doc ID 1118264.1)
Hope it Helps -
Java.sql.SQLException: Internal Error in RowSet
I�m getting the following error when running a JSF application on websphere 6.1
I have a class �MainSessionBean� class which extends AbstractSessionBean and in the init() method of my MainSessionBean class, I�m initializing some values like datasource, command like the following
pgmPriorityMaxValueRowSet.setDataSourceName("java:comp/env/jdbc/I5Dev");
pgmPriorityMaxValueRowSet.setCommand("SELECT max(AIPRGPRIO) as PRIORITY FROM TFTS341");
pgmPriorityMaxValueRowSet.setTableName("TFTS341");
pgmPriorityMaxValueRowSet.setTransactionIsolation(java.sql.Connection.TRANSACTION_NONE);
pgmPriorityMaxValueRowSet.setReadOnly(true);
pgmPriorityMaxValueRowSet.setPrintStatements(true);
The scope of this bean (MainSessionBean) is defined as �session in the managed-beans.xml.
So when application starts the init() method of my MainSessionBean class should get called right?
But the init() method is not getting called and the value of the datasource ,command etc are coming as null.
I�m trying to access the value �pgmPriorityMaxValueRowSet� in the MainSessionBean� with the following code.
private CachedRowSetDataProvider pgmPriorityMaxValueDataProvider = new CachedRowSetDataProvider();
pgmPriorityMaxValueDataProvider.setCachedRowSet((javax.sql.rowset.CachedRowSet)getValue("#{MainSessionBean.pgmPriorityMaxValueRowSet}"));
What can be the issue?
This application works fine in TOMCAT. But when I�m trying on websphere6.1 I�m getting the following error.
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R java.lang.RuntimeException: java.sql.SQLException: Internal Error in RowSetReader: no connection or command.
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.data.provider.impl.CachedRowSetDataProvider.setCursorRow(CachedRowSetDataProvider.java:343)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.data.provider.impl.CachedRowSetDataProvider.setCursorIndex(CachedRowSetDataProvider.java:300)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.data.provider.impl.CachedRowSetDataProvider.getRowKeys(CachedRowSetDataProvider.java:245)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.data.provider.impl.CachedRowSetDataProvider.cursorFirst(CachedRowSetDataProvider.java:351)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.capricorn.ai.allProgramsList.prerender(allProgramsList.java)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.prerender(ViewHandlerImpl.java:860)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.renderView(ViewHandlerImpl.java:295)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:220)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:118)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:966)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:907)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:145)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.capricorn.ai.security.SecurityFilter.doFilter(SecurityFilter.java:60)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:190)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:130)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:87)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:701)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:646)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:475)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:463)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3129)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:238)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1433)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:93)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:394)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:152)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:213)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(AbstractAsyncFuture.java:195)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:741)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R Caused by: java.sql.SQLException: Internal Error in RowSetReader: no connection or command.
at com.sun.sql.rowset.internal.CachedRowSetXReader.readData(CachedRowSetXReader.java:130)
Is there difference between the way session is handled in TOMCAT and websphere 6.1?I�m getting the following error when running a JSF application on websphere 6.1
I have a class �MainSessionBean� class which extends AbstractSessionBean and in the init() method of my MainSessionBean class, I�m initializing some values like datasource, command like the following
pgmPriorityMaxValueRowSet.setDataSourceName("java:comp/env/jdbc/I5Dev");
pgmPriorityMaxValueRowSet.setCommand("SELECT max(AIPRGPRIO) as PRIORITY FROM TFTS341");
pgmPriorityMaxValueRowSet.setTableName("TFTS341");
pgmPriorityMaxValueRowSet.setTransactionIsolation(java.sql.Connection.TRANSACTION_NONE);
pgmPriorityMaxValueRowSet.setReadOnly(true);
pgmPriorityMaxValueRowSet.setPrintStatements(true);
The scope of this bean (MainSessionBean) is defined as �session in the managed-beans.xml.
So when application starts the init() method of my MainSessionBean class should get called right?
But the init() method is not getting called and the value of the datasource ,command etc are coming as null.
I�m trying to access the value �pgmPriorityMaxValueRowSet� in the MainSessionBean� with the following code.
private CachedRowSetDataProvider pgmPriorityMaxValueDataProvider = new CachedRowSetDataProvider();
pgmPriorityMaxValueDataProvider.setCachedRowSet((javax.sql.rowset.CachedRowSet)getValue("#{MainSessionBean.pgmPriorityMaxValueRowSet}"));
What can be the issue?
This application works fine in TOMCAT. But when I�m trying on websphere6.1 I�m getting the following error.
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R java.lang.RuntimeException: java.sql.SQLException: Internal Error in RowSetReader: no connection or command.
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.data.provider.impl.CachedRowSetDataProvider.setCursorRow(CachedRowSetDataProvider.java:343)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.data.provider.impl.CachedRowSetDataProvider.setCursorIndex(CachedRowSetDataProvider.java:300)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.data.provider.impl.CachedRowSetDataProvider.getRowKeys(CachedRowSetDataProvider.java:245)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.data.provider.impl.CachedRowSetDataProvider.cursorFirst(CachedRowSetDataProvider.java:351)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.capricorn.ai.allProgramsList.prerender(allProgramsList.java)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.prerender(ViewHandlerImpl.java:860)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.renderView(ViewHandlerImpl.java:295)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:220)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:118)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:966)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:907)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:145)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.capricorn.ai.security.SecurityFilter.doFilter(SecurityFilter.java:60)
[7/22/08 19:07:46:812 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:190)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:130)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterChain._doFilter(WebAppFilterChain.java:87)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:701)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:646)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:475)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.wswebcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:463)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3129)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:238)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1433)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:93)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:394)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:102)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:152)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:213)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(AbstractAsyncFuture.java:195)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:741)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)
[7/22/08 19:07:46:828 EDT] 0000001e SystemErr R Caused by: java.sql.SQLException: Internal Error in RowSetReader: no connection or command.
at com.sun.sql.rowset.internal.CachedRowSetXReader.readData(CachedRowSetXReader.java:130)
Is there difference between the way session is handled in TOMCAT and websphere 6.1? -
Hello All,
Here is the issue description. Our application uses Oracle Object Types and LIST. We deployed our application on QA environment which has Oracle 10g. Application runs fine...no issues. Now we moved to UAT. UAT environment is same as QA environment and DBA have created replica of QA database.
Now WAR file which works fine with QA database , somehow doesnt work with UAT database. Application throws following exception when code tries to call getArray() on java.sql.Array.
We tried to point UAT weblogic to QA database and it worked fine.....but when we point UAT weblogic to UAT database , we get following exception. So we know that this is a database issue.
DBA claims that QA env database and UAT env database are same.
Can anybody please tell me what wrong here? What setting is not done on UAT database which is done on QA?
java.sql.SQLException: Internal Error at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:162) at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:227) at oracle.jdbc.oracore.OracleTypeCOLLECTION.initCollElemTypeName(OracleTypeCOLLECTION.java:975) at oracle.jdbc.oracore.OracleTypeCOLLECTION.getAttributeType(OracleTypeCOLLECTION.java:1005) at oracle.jdbc.oracore.OracleNamedType.getFullName(OracleNamedType.java:96) at oracle.jdbc.oracore.OracleTypeADT.createStructDescriptor(OracleTypeADT.java:1958) at oracle.jdbc.oracore.OracleTypeADT.unpickle81(OracleTypeADT.java:1432) at oracle.jdbc.oracore.OracleTypeUPT.unpickle81UPT(OracleTypeUPT.java:426) at oracle.jdbc.oracore.OracleTypeUPT.unpickle81rec(OracleTypeUPT.java:383) at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81_imgBody_elems(OracleTypeCOLLECTION.java:928) at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81_imgBody(OracleTypeCOLLECTION.java:872) at oracle.jdbc.oracore.OracleTypeCOLLECTION.unpickle81(OracleTypeCOLLECTION.java:692) at oracle.jdbc.oracore.OracleTypeCOLLECTION._unlinearize(OracleTypeCOLLECTION.java:217) at oracle.jdbc.oracore.OracleTypeCOLLECTION.unlinearize(OracleTypeCOLLECTION.java:189) at oracle.sql.ArrayDescriptor.toJavaArray(ArrayDescriptor.java:663) at oracle.sql.ARRAY.getArray(ARRAY.java:282) at weblogic.jdbc.wrapper.Array_oracle_sql_ARRAY.getArray(Unknown Source)
Please help.425260 wrote:
This can happen if you use the oracle.sql.ARRAY class with WebLogic.
WebLogic wraps oracle.sql.ARRAY with its own class (i.e. weblogic.jdbc.wrapper.Array_oracle_sql_ARRAY). The easiest solution is to replace oracle.sql.ARRAY with the JDBC standard java.sql.Array.
<PRE class=jive-pre><CODE class="jive-code jive-java">Object[] items = (Object[])array.getArray();
<FONT color=navy><B>if</B></FONT> (items.length > 0) <FONT color=navy>{</FONT>
<FONT color=navy><B>for</B></FONT> (<FONT color=navy><B>int</B></FONT> i = 0; i < items.length; i++) <FONT color=navy>{</FONT>
Object arrayItem = items;
<FONT color=navy>}</FONT>
<FONT color=navy>}</FONT>
</CODE></PRE>
The <B>array</B> object is a java.sql.Array. Here no unwrapping of the WebLogic wrapper is needed.
If you absolutely need the oracle.sql.ARRAY class than you must use an <B>unwrap</B> API on the WebLogic wrapper class.
<PRE class=jive-pre><CODE class="jive-code jive-java"><FONT color=navy><B>if</B></FONT> (object <FONT color=navy><B>instanceof</B></FONT> weblogic.jdbc.wrapper.Array)
array = (ARRAY) ( ((weblogic.jdbc.wrapper.Array)object).unwrap(Class.forName(<FONT color=red>"oracle.sql.ARRAY"</FONT>)) );
<FONT color=navy><B>else</B></FONT>
array = (ARRAY) object;
</CODE></PRE>
Here, <B>array</B> is an oracle.sql.ARRAY. Try to see if this <A class=bodylinkwhite href="http://www.software-to-convert.com/3gp-conversion-software/3gp-to-myspace-video-software.html"><FONT face=tahoma,verdana,sans-serif color=#000 size=1>helps</FONT></A>. Good luck.
Thanks for your explanation! It's very valuable, It is exactly what I need, I understand this part.
Maybe you are looking for
-
Multiple Problems with 4.2.1 update
Hi. I installed 4.2.1, and am experiencing multiple problems ever since. 1.) battery life is horrible I can fully charge it, and three or four hours later it is completely dead. 2.) wifi is wonky or, mostly, nonexistent 3.) ringtones vanished, and th
-
URGENT! PLEASE RESPOND! Ipod/Itunes trouble.
Please be patient while I try to explain all that's happening. Sorry if it's a little long, but I want to make sure I include all of the details so someone can actually help me: I am trying to disconnect my ipod from the computer by clicking the ejec
-
How to close the browser from webdynpro application
Hi All, I need to implement the closing the browser where the webdynpro application running by click on some button in that application. Can any body tell me how to implement that. Regards Vijay
-
Editing a web site created in MS Front Page
This may be a very simple question with a very simple answer: If a web site has been created, and was maintained, on a PC - how easy is it to take ownership and edit it using a Mac? (I am not a developer or anything close hence the possible stupidity
-
Hi, what is mean by import vendor and 3rd party? From this SAP ECC to Hubspan purchase order Mappings who is import vendor and 3rd party?. Please help me.