Retrieve blob data
i have some hexadecimal data inserted into blob datatype column in a table and i want to retrieve it ........... i used hextoraw function but unable to retrieve it.......... i tried using the command ------------dbms_lob.getlength(hextoraw(A.DOCUMENT))----- as part of the select statement ...... but it is showing
ORA-00932: inconsistent datatypes: expected - got BLOB as error ........ plzzz help me out ....... here DOCUMENT is the blob datatype column in the table PSA_KNOWLEDGE_TREE
Edited by: the_reckoner on Oct 21, 2009 4:08 AM
Hello:
'dbms_lob.getlength' needs a clob/blob/bfile as its argument.
select dbms_lob.getlength(A.DOCUMENT) from PSA_KNOWLEDGE_TREE A - will return the length of the blob named DOCUMENT from the PSA_KNOWLEDGE_TREE
You can read more about working with LOBs at http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14249/adlob_working.htm#i1010368
Varad
Similar Messages
-
How to store and retrieve blob data type in/from oracle database using JSP
how to store and retrieve blob data type in/from oracle database using JSP and not using servlet
thanksJSP? Why?
start here: [http://java.sun.com/developer/onlineTraining/JSPIntro/contents.html] -
How can i save and retrieve blob data through forms and reports...
I have blob data type column and I want to save word, html, gif
document in oracle database through forms 6 and retrieve the
data into forms and reports.
Details : I want to open .doc,.html,.gif file through a button
and save it ..and i want retrieve the data into text item same
in reports....
If anybody have the answer then send me at
[email protected]use ole container
initialize the container with the filename (doc or gif)
Edited by: arshid on Feb 8, 2009 1:57 PM -
Sending and retrieving blob data using JSP
I need to upload images to a database through a web page (jsp)
and then display them.
Environment is tomcat + mysql.
Anyone know a good site that explains
how to work with blobs through JSP?
thanks for any help!hello Sir,
I have to make a Image Library.
What I have done is I am just stroing the Image Path into the path
and retrieving the path from the database.
But now I am asked to Store the Image in the Database..
Could U Please tell me at the time of retrieving the Image
what exactly I have to do..
I am just 1 month new to JSP...(Practically)
Could U please write me the Code for Converting the BINARY Data into
InputStream ...
or what exactlt I have to do..
Please Guide me man..
Thanks In Advance...
With Regards
Eklavya -
How to retrieve the data stored in BLOB field in MySql using java?
Hi all!
i stored a file content into the MySql database in BLOB field.
and i now want retrieve the data......
Please help me out in doing the task...........
Thanx...........Thrisha..
When u get a result set u can have rs.getBlob() function that will give u a BLOB object that can be captured using Blob interface of javax.sql package...
Blob interface has getBinaryStream, getBytes etc as functions...
i think i cleared u
regards
Shanu -
Oracle 01g and forms 6i with BLOB Data type
Dear All,
I have upgraded my database from oracle 9i R2 to oracle 10g R2. i have an application developed using oracle forms and reports 6i. this application have a form where it stores and retirive an image from the database, this image is stored in a table with a BLOB data type, it was being retrieved fine until we did the upgrade and now it is impossible for me to see the image and i am getting an error every time i retrive the data. it always pop a message saying that "INCONSISTENT DATA TYPE"
please guys help.
Regardsyou can try this procedure
DECLARE
t_blob BLOB;
t_len NUMBER;
t_file_name VARCHAR2(100);
t_output UTL_FILE.file_type;
t_TotalSize number;
t_position number := 1;
t_chucklen NUMBER := 4096;
t_chuck raw(4096);
t_remain number;
BEGIN
-- Get length of blob
SELECT DBMS_LOB.getlength (PHOTO), ename || '_1.jpg'
INTO t_TotalSize, t_file_name FROM DEMO WHERE ENAME ='moon';
t_remain := t_TotalSize;
-- The directory TEMPDIR should exist before executing
t_output := UTL_FILE.fopen ('TEMPDIR', t_file_name, 'wb', 32760);
-- Get BLOB
SELECT PHOTO INTO t_blob FROM DEMO WHERE ENAME ='moon';
-- Retrieving BLOB
WHILE t_position < t_TotalSize
LOOP
DBMS_LOB.READ (t_blob, t_chucklen, t_position, t_chuck);
UTL_FILE.put_raw (t_output, t_chuck);
UTL_FILE.fflush (t_output);
t_position := t_position + t_chucklen;
t_remain := t_remain - t_chucklen;
IF t_remain < 4096
THEN
t_chucklen := t_remain;
END IF;
END LOOP;
END;
it will work -
Problem Updating BLOB Data in DB
Hi, There,
I have a problem when updating BLOB data in database table. I am
using Oracle 8.1.6, JDK1.3.0., oracle thin driver.
I have a Handle object handle (javax.ejb.Handle), and I need to
save this object in DB. The table has 2 columns: column 1
is "PK" Varchar2(30) Primary Key, column 2 is "HANDLE" BLOB.
According to the documentation I found from Oracle, I first
initialize the blob column, and then get the BLOB locator.
However when I try to update the BLOB data by invoking
executeUpdate() method on OraclePreparedStatement ops, I always
get the returned int rowCount=0, which indicates that no rows
have been updated. (This is verified by trying to retrieve the
BLOB column value which results in SQLException: Exhausted
Resultset.)
Any suggestions what was wrong with the code? Thank you a lot in
advance!
Tom
Part of the code is listed below:
// If jSessionID is not found, create it
HttpSession session = request.getSession(true);
String jSessionID = session.getId();
//get the Hanlde object for MemberInfo bean
javax.ejb.Handle handle = memberValidate.validateMember(
memberID, "" );
oracle.sql.BLOB oracleBlob = null;
/* Get DB connection */
try
Connection conn = getDBConnection(); // with oracle thin driver
conn.setAutoCommit(false);
catch (NamingException ne)
System.out.println( "Failed to getDBConnection due to Naming
Exception" + ne.toString() );
return;
catch (SQLException sqle)
System.out.println( "Failed to getDBConnection due to SQL
Exception"+ sqle.toString() );
return;
try
pstmt=conn.prepareStatement("CREATE TABLE TOM1 (PK VARCHAR(30)
PRIMARY KEY, HANDLE BLOB NOT NULL)");
pstmt.execute();
pstmt=conn.prepareStatement("INSERT INTO TOM1 VALUES('ROW1',
EMPTY_BLOB())");
pstmt.executeUpdate();
pstmt=conn.prepareStatement("SELECT HANDLE FROM TOM1 WHERE
PK=? FOR UPDATE");
pstmt.setString(1, "ROW1");
ResultSet rset = pstmt.executeQuery();
if ( rset.next() )
// Get the LOB locator from the ResultSet
oracleBlob = ((OracleResultSet)rset).getBLOB("HANDLE");
OraclePreparedStatement ops = null;
ops = ( OraclePreparedStatement )
(conn.prepareStatement("UPDATE TOM1 SET HANDLE = ?
WHERE PK = ?"));
ops.setString( 2, jSessionID );
// using OutputStream to write object data
OutputStream oStream = oracleBlob.getBinaryOutputStream();
ObjectOutputStream outStream = new ObjectOutputStream
(oStream);
outStream.writeObject(handle); // handle is the Object to be
saved
outStream.close();
conn.commit();
conn.setAutoCommit(true);
ops.setBLOB( 1, oracleBlob );
int rowCount = ops.executeUpdate();
System.out.println("\n**** Rows affected: ");
System.out.println(ops.executeUpdate());
if (rowCount != 0)
// Commit the transaction:
System.out.println("\n**** conn.commit() OK...");
System.out.println("\n**** Handle saved in DB as Blob-type
OK...");
conn.commit();
conn.close();
else
System.out.println("\n**** ops.executeUpdate() == 0, Failed
to update DB");
conn.close();
return;
catch ( SQLException se )
se.printStackTrace();
return;
catch ( Exception e )
System.out.println(e.toString());
return;
System.out.println("\n**** DB update OK...");
nullYou cannot update Blob column in Adf testing tool as far i think
check this blog might help you to store images in ADF http://baigsorcl.blogspot.com/2010/09/store-images-in-blob-in-oracle-adf.html -
After a Lion clean install, how do I retrieve my data from external hard drive?
Following Apple advice I used Migration Assistant which crashed new system twice which is why I had to clean install Lion in the first place.
Is there a sure way of doing it?
I have only a few programs that I will have to install myself and that should not be a problem.
I just want my data, music and photos back where I can use them.Time machine backups. I went to migration assistant a few hours ago and limited my selection to "users", no need for applications, settings and other files. Stuff started moving over at a fast pace but has now seemed to stall.
I will let it run overnight as there are lots of songs and photos as well as a few movies.
If that does not work, then I will go into TM and try restore. I have restored some things in the past such a mail files and it has worked well.
The Apple fellow at the store told me to go right into TM, he may have had a point. I'll get it eventually. -
Not able to Retrieve Transaction Data based on the property of master data
Hi,
I am trying to retrieve transaction data based on property of Master Data for ACCOUNT (property ACCTYPE = ‘EXP’)
in BPC 10 version for netweaver.
Transaction data is present at backend, But I am not getting data in Internal table after running RSDRI Query.
I am using this code.
DATA: lt_sel TYPE uj0_t_sel,
ls_sel TYPE uj0_s_sel.
ls_sel-dimension = 'ACCOUNT'.
ls_sel-attribute = 'ACCTYPE'.
ls_sel-sign = 'I'.
ls_sel-option = 'EQ'.
ls_sel-low = 'EXP'.
APPEND ls_sel TO lt_sel.
lo_query = cl_ujo_query_factory=>get_query_adapter(
i_appset_id = lv_environment_id
i_appl_id = lv_application_id ).
lo_query->run_rsdri_query(
EXPORTING
it_dim_name = lt_dim_list " BPC: Dimension List
it_range = lt_sel" BPC: Selection condition
if_check_security = ABAP_FALSE " BPC: Generic indicator
IMPORTING
et_data = <lt_query_result>
et_message = lt_message
Data is coming if i use ID of ACCOUNT directly, for e.g.
ls_sel-dimension = 'ACCOUNT'.
ls_sel-attribute = 'ID'.
ls_sel-sign = 'I'.
ls_sel-option = 'EQ'.
ls_sel-low = 'PL110.
APPEND ls_sel TO lt_sel.
so in this case data is coming , but it is not coming for property.
So Please can you help me on this.
Thanks,
RishiHi Rishi,
There are 2 steps you need to do,.
1. read all the master data with the property you required into a internal table. in your case use ACCTYPE' = EXP
2. read transaction data with the masterdata you just selected.
Then you will get all your results.
Andy -
Pb retrieving sorted data from Table in SQL.
Hi,
I get problem to retrieve data in the right order from table in database SQL.
See code attached: code.png
I want to sort data according to ID number And then to retrieve those data and fill out a ring control in the right order "descending" .
But i got always ID 2 instead of 1. See attached picture : control.png
it seems that the select statement (see under) is not woking properly. But it is working well in a query in Access DataBase .
//Select statement
hstmt = DBActivateSQL (hdbc, ("SELECT * FROM %s ORDER BY ID DESCENDING",szTableName));
if (hstmt<= DB_SUCCESS) {ShowError(); goto Error;}
Some idea ??
Lionel.
Attachments:
code.PNG 39 KB
control.png 32 KBHello Lionel,
According to the document Robert linked, the prototype of DBActivateSQL() is:
int statementHandle = DBActivateSQL (int connectionHandle, char SQLStatement[]);
For the 2nd parameter(SQLStatement), you're sending:
("SELECT * FROM %s ORDER BY ID DESCENDING",szTableName)
Probably your intention is to substitute %s with szTableName, but that's not what it happens.
By using comma operator, ("SELECT * FROM %s ORDER BY ID DESCENDING",szTableName) is evaluated to szTableName, so you call is equivalent to:
hstmt = DBActivateSQL (hdbc, szTableName);
In order to substitute %s with szTableName you need to first build the string you're passing as the 2nd parameter:
char query[512];
sprintf(query, "SELECT * FROM %s ORDER BY ID DESCENDING",szTableName);
hstmt = DBActivateSQL (hdbc, query); -
How to retrieve input data from a HTML form in the UTF-8 cha
I encountered the following problem with a JWeb Application:
I tried to write a JWeb-Application for OAS 4.0, that retrieves
input data from a HTML form and writes it into an Oracle
database.
All processing should be done in the UTF-8 character set.
The problem is, that the form data retrieved by getURLParameter
are always encoded in a non-unicode character set and I found no
way to change this.
Can anybody tell me what I should do to get the form data in the
UTF-8 character set?
nullHi
Try set in the JWEB application's Java environment such
SYSTEM_PROPERTY: file.encoding=UTF8.
Andrew
Thomas Gertkemper (guest) wrote:
: I encountered the following problem with a JWeb Application:
: I tried to write a JWeb-Application for OAS 4.0, that
retrieves
: input data from a HTML form and writes it into an Oracle
: database.
: All processing should be done in the UTF-8 character set.
: The problem is, that the form data retrieved by getURLParameter
: are always encoded in a non-unicode character set and I found
no
: way to change this.
: Can anybody tell me what I should do to get the form data in
the
: UTF-8 character set?
null -
Using a BLOB data type in a CMP Entity Bean: Error when send large files
I've successfully impleenting BLOB in my EJB. But the main prob is, it can only work on small file which is around 3K. Any larger files than that will caused error (refer below). I got info from a friend which is using normal JDBC call to insert a file into BLOB column that you can't use java.sql.Blob data type which will have this limitation. He suggested that by using oracle.sql.BLOB, this prob won't exist.
The problem is I'm unable to use oracle.sql.BLOB in my CMP EJB because in the jbosscmp-jdbc.xml, I'm able to specify the normal BLOB only which is java.sql.Blob (Refer below).
<cmp-field>
<field-name>attachment</field-name>
<column-name>attch</column-name>
<jdbc-type>BLOB</jdbc-type>
<sql-type>BLOB</sql-type>
</cmp-field>So, how do I solve this problem? I need to store files which the size is much bigger than that. I'm using JBoss 4 as my app server and Oracle 9i as my DB. I can see that there's many ppl facing this prob, but no solution to it. Pls advise. Thanks.
20:03:34,218 INFO [Server] JBoss (MX MicroKernel) [4.0.1RC1 (build: CVSTag=JBoss_4_0_1_RC1 date=200411041143)] Started in 1m:49s:828ms
20:05:01,640 ERROR [EBCreditApplAttch] Could not create entity
java.sql.SQLException: No more data to read from socket
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:187)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:229)
at oracle.jdbc.dbaccess.DBError.check_error(DBError.java:982)
at oracle.jdbc.ttc7.MAREngine.unmarshalUB1(MAREngine.java:746)
at oracle.jdbc.ttc7.MAREngine.unmarshalSB1(MAREngine.java:705)
at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:373)
at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1477)
at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:888)
at oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:2051)
at oracle.jdbc.driver.OracleStatement.doExecuteOther(OracleStatement.java:1961)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2672)
at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:452)
at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.executeUpdate(WrappedPreparedStatement.java:316)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand.executeInsert(JDBCAbstractCreateCommand.java:328)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand.performInsert(JDBCAbstractCreateCommand.java:286)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand.execute(JDBCAbstractCreateCommand.java:137)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.createEntity(JDBCStoreManager.java:572)
at org.jboss.ejb.plugins.CMPPersistenceManager.createEntity(CMPPersistenceManager.java:222)
at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.createEntity(CachedConnectionInterceptor.java:266)
at org.jboss.ejb.EntityContainer.createLocalHome(EntityContainer.java:612)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.invocation.Invocation.performCall(Invocation.java:345)
at org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(EntityContainer.java:1113)
at org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:90)
at org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome(EntitySynchronizationInterceptor.java:192)
at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invokeHome(CachedConnectionInterceptor.java:212)
at org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:90)
at org.jboss.ejb.plugins.EntityInstanceInterceptor.invokeHome(EntityInstanceInterceptor.java:113)
at org.jboss.ejb.plugins.EntityLockInterceptor.invokeHome(EntityLockInterceptor.java:61)
at org.jboss.ejb.plugins.EntityCreationInterceptor.invokeHome(EntityCreationInterceptor.java:28)
at org.jboss.ejb.plugins.CallValidationInterceptor.invokeHome(CallValidationInterceptor.java:41)
at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:109)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:313)
at org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:126)
at org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:100)
at org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:120)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invokeHome(ProxyFactoryFinderInterceptor.java:93)
at org.jboss.ejb.EntityContainer.internalInvokeHome(EntityContainer.java:508)
at org.jboss.ejb.Container.invoke(Container.java:878)
at org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invokeHome(BaseLocalProxyFactory.java:342)
at org.jboss.ejb.plugins.local.LocalHomeProxy.invoke(LocalHomeProxy.java:118)
at $Proxy94.create(Unknown Source)
at com.infopro.dt.app.ca.ejb.SBCreditApplAttch.setCreditApplAttch(SBCreditApplAttch.java:148)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.invocation.Invocation.performCall(Invocation.java:345)
at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:214)
at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:185)
at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:113)
at org.jboss.webservice.server.ServiceEndpointInterceptor.invoke(ServiceEndpointInterceptor.java:51)
at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:48)
at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:105)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:313)
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:146)
at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:122)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
at org.jboss.ejb.Container.invoke(Container.java:856)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:805)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:406)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:534)
20:05:01,656 ERROR [JDBCUtil] SQL error
java.sql.SQLException: No more data to read from socket
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:187)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:229)
at oracle.jdbc.dbaccess.DBError.check_error(DBError.java:982)
at oracle.jdbc.ttc7.MAREngine.unmarshalUB1(MAREngine.java:746)
at oracle.jdbc.ttc7.MAREngine.unmarshalSB1(MAREngine.java:705)
at oracle.jdbc.ttc7.Oclose.receive(Oclose.java:105)
at oracle.jdbc.ttc7.TTC7Protocol.close(TTC7Protocol.java:565)
at oracle.jdbc.driver.OracleStatement.close(OracleStatement.java:824)
at oracle.jdbc.driver.OraclePreparedStatement.privateClose(OraclePreparedStatement.java:346)
at oracle.jdbc.driver.OraclePreparedStatement.close(OraclePreparedStatement.java:280)
at org.jboss.resource.adapter.jdbc.WrappedStatement.internalClose(WrappedStatement.java:782)
at org.jboss.resource.adapter.jdbc.WrappedStatement.close(WrappedStatement.java:52)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCUtil.safeClose(JDBCUtil.java:92)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand.performInsert(JDBCAbstractCreateCommand.java:310)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCAbstractCreateCommand.execute(JDBCAbstractCreateCommand.java:137)
at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.createEntity(JDBCStoreManager.java:572)
at org.jboss.ejb.plugins.CMPPersistenceManager.createEntity(CMPPersistenceManager.java:222)
at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.createEntity(CachedConnectionInterceptor.java:266)
at org.jboss.ejb.EntityContainer.createLocalHome(EntityContainer.java:612)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.invocation.Invocation.performCall(Invocation.java:345)
at org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(EntityContainer.java:1113)
at org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:90)
at org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome(EntitySynchronizationInterceptor.java:192)
at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invokeHome(CachedConnectionInterceptor.java:212)
at org.jboss.ejb.plugins.AbstractInterceptor.invokeHome(AbstractInterceptor.java:90)
at org.jboss.ejb.plugins.EntityInstanceInterceptor.invokeHome(EntityInstanceInterceptor.java:113)
at org.jboss.ejb.plugins.EntityLockInterceptor.invokeHome(EntityLockInterceptor.java:61)
at org.jboss.ejb.plugins.EntityCreationInterceptor.invokeHome(EntityCreationInterceptor.java:28)
at org.jboss.ejb.plugins.CallValidationInterceptor.invokeHome(CallValidationInterceptor.java:41)
at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:109)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:313)
at org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:126)
at org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterceptor.java:100)
at org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:120)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invokeHome(ProxyFactoryFinderInterceptor.java:93)
at org.jboss.ejb.EntityContainer.internalInvokeHome(EntityContainer.java:508)
at org.jboss.ejb.Container.invoke(Container.java:878)
at org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invokeHome(BaseLocalProxyFactory.java:342)
at org.jboss.ejb.plugins.local.LocalHomeProxy.invoke(LocalHomeProxy.java:118)
at $Proxy94.create(Unknown Source)
at com.infopro.dt.app.ca.ejb.SBCreditApplAttch.setCreditApplAttch(SBCreditApplAttch.java:148)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.invocation.Invocation.performCall(Invocation.java:345)
at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:214)
at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:185)
at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:113)
at org.jboss.webservice.server.ServiceEndpointInterceptor.invoke(ServiceEndpointInterceptor.java:51)
at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:48)
at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:105)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:313)
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:146)
at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:122)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
at org.jboss.ejb.Container.invoke(Container.java:856)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:805)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:406)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:534)
20:05:01,672 WARN [JBossManagedConnectionPool] Exception destroying ManagedConnection org.jboss.resource.connectionmanager.TxConnectionManager$TxConnectionEventListener@87b71b[state=DESTROYED mc=org.jboss.resource.adapter.jdbc.local.LocalManagedConnection@225f0 handles=0 lastUse=1110456252484 permit=false trackByTx=false mcp=org.jboss.resource.connectionmanager.JBossManagedConnectionPool$OnePool@108bef4 context=org.jboss.resource.connectionmanager.InternalManagedConnectionPool@1309516]
org.jboss.resource.JBossResourceException: SQLException; - nested throwable: (java.sql.SQLException: Io exception: Software caused connection abort: socket write error)
at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.checkException(BaseWrapperManagedConnection.java:541)
at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.destroy(BaseWrapperManagedConnection.java:255)
at org.jboss.resource.connectionmanager.InternalManagedConnectionPool.doDestroy(InternalManagedConnectionPool.java:539)
at org.jboss.resource.connectionmanager.InternalManagedConnectionPool.returnConnection(InternalManagedConnectionPool.java:329)
at org.jboss.resource.connectionmanager.JBossManagedConnectionPool$BasePool.returnConnection(JBossManagedConnectionPool.java:552)
at org.jboss.resource.connectionmanager.BaseConnectionManager2.returnManagedConnection(BaseConnectionManager2.java:407)
at org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.commit(TxConnectionManager.java:699)
at org.jboss.tm.TransactionImpl$Resource.commit(TransactionImpl.java:2141)
at org.jboss.tm.TransactionImpl.commitResources(TransactionImpl.java:1674)
at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:312)
at org.jboss.ejb.plugins.TxInterceptorCMT.endTransaction(TxInterceptorCMT.java:454)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:322)
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:146)
at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:122)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
at org.jboss.ejb.Container.invoke(Container.java:856)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:805)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:406)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:534)
Caused by: java.sql.SQLException: Io exception: Software caused connection abort: socket write error
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:187)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:229)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:342)
at oracle.jdbc.driver.OracleConnection.close(OracleConnection.java:1438)
at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.destroy(BaseWrapperManagedConnection.java:251)
... 38 more
20:05:01,687 WARN [TransactionImpl] XAException: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=waikitteoh/17, BranchQual=, localId=17] errorCode=XA_UNKNOWN(0)
org.jboss.resource.connectionmanager.JBossLocalXAException: could not commit local tx; - nested throwable: (org.jboss.resource.JBossResourceException: SQLException; - nested throwable: (java.sql.SQLException: Io exception: Software caused connection abort: socket write error))
at org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.commit(TxConnectionManager.java:702)
at org.jboss.tm.TransactionImpl$Resource.commit(TransactionImpl.java:2141)
at org.jboss.tm.TransactionImpl.commitResources(TransactionImpl.java:1674)
at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:312)
at org.jboss.ejb.plugins.TxInterceptorCMT.endTransaction(TxInterceptorCMT.java:454)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:322)
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:146)
at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:122)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
at org.jboss.ejb.Container.invoke(Container.java:856)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:805)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:406)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:534)
Caused by: org.jboss.resource.JBossResourceException: SQLException; - nested throwable: (java.sql.SQLException: Io exception: Software caused connection abort: socket write error)
at org.jboss.resource.adapter.jdbc.BaseWrapperManagedConnection.checkException(BaseWrapperManagedConnection.java:541)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.commit(LocalManagedConnection.java:100)
at org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.commit(TxConnectionManager.java:695)
... 33 more
Caused by: java.sql.SQLException: Io exception: Software caused connection abort: socket write error
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:187)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:229)
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:342)
at oracle.jdbc.driver.OracleConnection.commit(OracleConnection.java:1344)
at org.jboss.resource.adapter.jdbc.local.LocalManagedConnection.commit(LocalManagedConnection.java:96)
... 34 more
20:05:01,718 WARN [TransactionImpl] XAException: tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=waikitteoh/17, BranchQual=, localId=17] errorCode=XA_UNKNOWN(0)
org.jboss.resource.connectionmanager.JBossLocalXAException: wrong xid in rollback: expected: null, got: XidImpl[FormatId=257, GlobalId=waikitteoh/17, BranchQual=1, localId=17]
at org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource.rollback(TxConnectionManager.java:774)
at org.jboss.tm.TransactionImpl$Resource.rollback(TransactionImpl.java:2165)
at org.jboss.tm.TransactionImpl.rollbackResources(TransactionImpl.java:1727)
at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:340)
at org.jboss.ejb.plugins.TxInterceptorCMT.endTransaction(TxInterceptorCMT.java:454)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:322)
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:146)
at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:122)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
at org.jboss.ejb.Container.invoke(Container.java:856)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:805)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:406)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:534)
20:05:01,734 ERROR [LogInterceptor] TransactionRolledbackException in method: public abstract void com.infopro.dt.app.ca.ejb.SBCreditApplAttchRemote.setCreditApplAttch(com.infopro.dt.app.ca.ejb.DTOCreditApplAttch) throws javax.ejb.CreateException,java.lang.Exception,java.rmi.RemoteException, causedBy:
org.jboss.tm.JBossRollbackException: Unable to commit, tx=TransactionImpl:XidImpl[FormatId=257, GlobalId=waikitteoh/17, BranchQual=, localId=17] status=STATUS_NO_TRANSACTION; - nested throwable: (org.jboss.resource.connectionmanager.JBossLocalXAException: could not commit local tx; - nested throwable: (org.jboss.resource.JBossResourceException: SQLException; - nested throwable: (java.sql.SQLException: Io exception: Software caused connection abort: socket write error)))
at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:344)
at org.jboss.ejb.plugins.TxInterceptorCMT.endTransaction(TxInterceptorCMT.java:454)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:322)
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:146)
at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:122)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)
at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:624)
at org.jboss.ejb.Container.invoke(Container.java:856)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:144)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:249)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
at org.jboss.invocation.jrmp.server.JRMPInvoker$MBeanServerAction.invoke(JRMPInvoker.java:805)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:406)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
at java.lang.Thread.run(Thread.java:534)
Caused by: org.jboss.resource.connectionmanager.JBossLocalXAException: could not commit local tx; - nested throwable: (org.jboss.resource.JBossResourceException: SQLException; - nested throwable: (java.sql.SQLException: Io exceptionTry to use the OCI native driver instead of THIN.
-
How to retrieve multiple data from table and represent it in jsp page
Hi
The below JavaScript code is used to add row in the table when I want to add multiple row data into table for single entry no field.
<html> function addRow()
i++;
var newRow = document.all("tblGrid").insertRow();
var oCell = newRow.insertCell();
oCell.innerHTML = "<input name='srno"+i+"' type='text' id='srno"+i+"' size=10>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='itmcd"+i+"' type='text' id='itmcd"+i+"' size='10'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='itmnm"+i+"' type='text' id='itmnm"+i+"' size='15'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='indentqty"+i+"' type='text' id='indentqty"+i+"' size='10'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='uom"+i+"' type='text' id='uom"+i+"' size='10'><input type='hidden' name='mcode"+i+"'id='mcode"+i+"'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='packqty"+i+"' type='text' id='packqty"+i+"' size='10'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='packuom"+i+"' type='text' id='packuom"+i+"' size='10'><input type='hidden' name='pack"+i+"' id='pack"+i+"'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='rate"+i+"' type='text' id='rate"+i+"' size='10'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='dor"+i+"' type='text' id='dor"+i+"' size='0' onClick='"+putdate(this.name)+"'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='bccode"+i+"' type='text' id='bccode"+i+"' size='10'></td><input type='hidden' name='bcc"+i+"' id='bcc"+i+"'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='cccode"+i+"' type='text' id='cccode"+i+"' size='10'></td><input type='hidden' name='ccc"+i+"' id='ccc"+i+"'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input name='remark2"+i+"' type='text' id='remark2"+i+"' size='20'>";
oCell = newRow.insertCell();
oCell.innerHTML = "<input type='button' value='Delete' onclick='removeRow(this);' />";
// oCell = newRow.insertCell();
// oCell.innerHTML = "<input type='button' value='Clear' onclick='clearRow(this);' />";
}<html> Then this data are send to the next Servlet for adding into two table.
My header portion data are added into one table which added only one row in table. while footer section data are added into the no of rows in another table dependent on No. of
Rows added into jsp page.
Here is an code for that logic.
<html>
ArrayList<String> mucode = new ArrayList<String>();
ArrayList<Integer> serials = new ArrayList<Integer>();
ArrayList<Integer> apxrate = new ArrayList<Integer>();
ArrayList<Integer> srname = new ArrayList<Integer>();
ArrayList<String> itcode = new ArrayList<String>();
ArrayList<String> itname = new ArrayList<String>();
ArrayList<Integer> iqnty = new ArrayList<Integer>();
ArrayList<String> iuom = new ArrayList<String>();
ArrayList<Integer> pqnty = new ArrayList<Integer>();
ArrayList<String> puom1 = new ArrayList<String>();
ArrayList<Integer> arate = new ArrayList<Integer>();
ArrayList<String> rdate = new ArrayList<String>();
ArrayList<String> bcs = new ArrayList<String>();
ArrayList<String> ccs = new ArrayList<String>();
ArrayList<String> remarkss = new ArrayList<String>();
//ArrayList<Integer> qtyrecs = new ArrayList<Integer>();
//ArrayList<String> dors = new ArrayList<String>();
//ArrayList<String> remarks = new ArrayList<String>();
String entryn = request.getParameter("entryno");
String rows = request.getParameter("rows");
out.println(rows);
//String Entryno = request.getParameter("entryno");
// out.println(Entryno);
int entryno = 0,reqqty = 0,srno = 0,deprequest = 0,rowcount = 0;
if(!Entryno.equals("")){
entryno = Integer.valueOf(Entryno);
if(!rows.equals("")){
rowcount = Integer.valueOf(rows);
for(int i=1;i<=rowcount;i++){
if(request.getParameter("srno"+i)!=null){
serials.add(Integer.valueOf(request.getParameter("srno"+i).trim()));
out.println(serials.size());
for(int i=1;i<=rowcount;i++){
if(request.getParameter("srno"+i)!=null){
srname.add(Integer.valueOf(request.getParameter("srno"+i).trim()));
out.println(srname.get(0));
for(int i=1;i<=rowcount;i++){
if(request.getParameter("itmcd"+i)!=null){
itcode.add(request.getParameter("itmcd"+i).trim());
} //out.println(itcode.get(i));
for(int i=1;i<=rowcount;i++){
if(request.getParameter("itmnm"+i)!=null){
itname.add(request.getParameter("itmnm"+i).trim());
}//out.println(itname.get(i));
for(int i=1;i<=rowcount;i++){
if(request.getParameter("indentqty"+i)!=null){
iqnty.add(Integer.valueOf(request.getParameter("indentqty"+i).trim()));
for(int i=1;i<=rowcount;i++){
if(request.getParameter("uom"+i)!=null){
iuom.add(request.getParameter("uom"+i).trim());
}//out.println(iuom.get(i));
for(int i=1;i<=rowcount;i++){
if(request.getParameter("mcode"+i)!=null){
mucode.add(request.getParameter("mcode"+i).trim());
for(int i=1;i<=rowcount;i++){
if(request.getParameter("packqty"+i).equals("")){
pqnty.add(0);
}else
pqnty.add(Integer.valueOf(request.getParameter("packqty"+i).trim()));
for(int i=1;i<=rowcount;i++){
if(request.getParameter("pack"+i)!=null){
puom1.add(request.getParameter("pack"+i).trim());
}else
puom1.add("");
for(int i=1;i<=rowcount;i++){
if(request.getParameter("rate"+i).equals("")){
arate.add(0);
}else
arate.add(Integer.valueOf(request.getParameter("rate"+i).trim()));
/* for(int i=1;i<=rowcount;i++){
if(request.getParameter("rate"+i)!=null){
arate.add(Integer.valueOf(request.getParameter("rate"+i).trim()));
for(int i=1;i<=rowcount;i++){
if(request.getParameter("dor"+i)!=null){
try{
rdate.add(dashdate.format(slashdate.parse(request.getParameter("dor"+i).trim())));
}catch(ParseException p){p.printStackTrace();}
}else
{ rdate.add("");}
for(int i=1;i<=rowcount;i++){
if(request.getParameter("bcc"+i)!=null){
bcs.add(request.getParameter("bcc"+i).trim());
}out.println(bcs.get(0));
for(int i=1;i<=rowcount;i++){
if(request.getParameter("ccc"+i)!=null){
ccs.add(request.getParameter("ccc"+i).trim());
}out.println(ccs.get(0));
for(int i=1;i<=rowcount;i++){
out.println("remark2");
if(request.getParameter("remark2"+i)!=null){
remarkss.add(request.getParameter("remark2"+i).trim());
}out.println(remarkss.get(0));
ArrayList<String> Idate = new ArrayList<String>();
for(int i=1;i<=rowcount;i++){
if(request.getParameter("dateindent"+i)!=null){
try{
Idate.add(dashdate.format(dashdate.parse(request.getParameter("dateindent"+i).trim())));
}catch(ParseException p){p.printStackTrace();}
String Rdate = dashdate.format(new java.util.Date());
String tdate = dashdate.format(new java.util.Date());
// String Indentdate = dashdate.format(new java.util.Date());
// String ApprovedT1 = dashdate.format(new java.util.Date());
// String ApprovedT2 = dashdate.format(new java.util.Date());
// String ApprovedT1=" ";
//String ApprovedT2="";*/
String ApprovedT1= dashdate.format(new java.util.Date());
out.println (ApprovedT1);
String ApprovedT2=dashdate.format(new java.util.Date());
out.println(ApprovedT2);
String Indentdate=(dashdate.format(slashdate.parse(request.getParameter("dateindent").trim())));
out.println(Indentdate);
String Cocode ="BML001";
out.println(Cocode);
String Deptcode = request.getParameter("dept1");
out.println(Deptcode);
String Empcode = request.getParameter("emp");
out.println(Empcode);
String Refno =request.getParameter("rtype");
out.println(Refno);
String Divcode = request.getParameter("todiv1");
out.println(Divcode);
String Usercode = "CIRIUS";
String Whcode = request.getParameter("stor");
out.println(Whcode);
// String Itemgroupcode = request.getParameter("");
String Itemgroupcode ="120000";
out.println(Itemgroupcode);
String Supplytypecode = request.getParameter("stype");
out.println(Supplytypecode);
String Delcode = request.getParameter("deliverycode");
out.println(Delcode);
String Itemclass="WS";
out.println(Itemclass);
// String Itemclass = request.getParameter("iclass");
// out.println(Itemclass);
String unitcode = request.getParameter("uni");
out.println(unitcode);
String Todivcode = request.getParameter("todiv1");
out.println(Todivcode);
String Appxrate = request.getParameter("rate");
out.println(Appxrate);
String Srno = request.getParameter("srno");
out.println(Srno);
/* String Indqty = request.getParameter("indentqty");
out.println(Indqty);*/
String Itemcode = request.getParameter("itmcd");
out.println(Itemcode);
String Othersp = request.getParameter("remark1");
out.println(Othersp);
String Reqdt = request.getParameter("dor");
out.println(Reqdt);
String Munitcode = request.getParameter("mcode");
out.println(Munitcode);
String Packqty = request.getParameter("packqty");
out.println(Packqty);
String Packuom = request.getParameter("pack");
out.println(Packuom);
String Remark2 = request.getParameter("remark2");
out.println(Remark2);
String BC = request.getParameter("bcc");
out.println(BC);
String CC = request.getParameter("ccc");
out.println(CC);
try{
st=connection.createStatement();
connection.setAutoCommit(false);
String sql="INSERT INTO PTXNINDHDR(COCODE,DEPTCODE,EMPCODE,APPROVEDT1,APPROVEDT2,INDDT,ENTRYNO,REFNO,REMARKS,DIVCODE,USERCODE,WHCODE,ITEMGROUPCODE,SUPTYPECODE,DELCODE,UNITCODE,TODIVCODE,ITEMCLASS)VALUES('"+Cocode+"','"+Deptcode+"','"+Empcode+"','"+ApprovedT1+"','"+ApprovedT2+"','"+Indentdate+"',"+Entryno+",'"+Refno+"','"+Othersp+"','"+Divcode+"','"+Usercode+"','"+Whcode+"','"+Itemgroupcode+"','"+Supplytypecode+"','"+Delcode+"','"+unitcode+"','"+Todivcode+"','"+Itemclass+"')";
out.println(sql);
st.addBatch(sql);
for(int i=0;i<serials.size();i++){
out.println("Inside the Statement");
String query3="test query for u";
out.println(query3);
String queryx="Insert into PTXNINDDTL(APXRATE,ENTRYNO,BRKNO,INDQTY,ITEMCODE,OTHERSPFCS,MUNITCODE,PACKQTY,PACKUOM,REMARKS,DIMSUBGRPCODE,DIMCODE,REQDT)VALUES("+arate.get(i)+","+entryno+","+srname.get(i)+","+iqnty.get(i)+","+itcode.get(i)+",'"+Othersp+"','"+mucode.get(i)+"',"+pqnty.get(i)+",'"+puom1.get(i)+"','"+remarkss.get(i)+"','"+bcs.get(i)+"','"+ccs.get(i)+"','"+rdate.get(i)+"')";
out.println(queryx);
st.addBatch(queryx);
int[] result=st.executeBatch();
connection.commit();
for(int k=0;k<result.length;k++)
out.println("rows updated by "+(k+1)+"insert sta:"+result[k]+"");
catch(BatchUpdateException bue)
out.println("error1;"+bue+"");
catch(SQLException sql)
out.println("error2;"+sql+"");
catch(Exception l)
out.println("error3;"+l+"");
</html>
Now I looking for to retrieve this footer section data available in multiple rows from footer table and present it in jsp page .
I am finding difficulties in how to show this multiple row data for dynamic no of rows .i.e. variable no. of rows.
I have able to show the data in Header portions of page in this ways
here i am adding the part of code which shows the data from header part of table i.e from Header table
<html>
<h2 align="center"><b>Indent Preparation</b></h2>
<div align="left">
<table width="849" border="0" cellspacing="3" cellpadding="3" align="center">
<tr>
<td ><div align="left"><b>Indent No.</b></div></td>
<td ><label>
<input name="indentno" type="text" id="indentno" size="15" value="" /><input type="hidden" name="no" id="no">
</label></td>
<td ><div align="center"><strong>Indent Date</strong></div></td>
<td ><label>
<div align="center">
<input name="dateindent" type="text" id="dateindent"value="<%=date1%>"/><input type="hidden" name="no" id="no">
</div>
</label></td>
<td> </td>
<td><div align="right"><strong>Entry No.</strong></div></td>
<%if(oper!=null && oper.equals("view") && hdrcode!=null && hdrdetails!=null){%>
<td><input type="text" value="<%=hdrcode.get(3)%>" size="10"></td>
<%}else{%>
<td><input type="text" name="entryno" id="entryno" value="<%=entryNo%>"/></td>
<%}%>
<div align="right"></div>
</tr>
<tr>
<td><b>Division</b></td>
<%if(oper!=null && oper.equals("view") && hdrcode!=null && hdrdetails!=null){%>
<td><input type="text" value="<%=hdrdetails.get(9)%>" size="20"</td>
<td><input type="hidden" name="div1" id="div1" value='<%=hdrcode.get(10)%>'></td>
<%}else{%>
<td><input type="text" name="div" id="div" /></td>
<td><input type="hidden" name="div1" id="div1" /> </td>
<%}%>
<td> </td>
<td> </td>
<td><div align="right"><strong>Unit</strong></div></td>
<%if(oper!=null && oper.equals("view") && hdrcode!=null && hdrdetails!=null){%>
<td><input type="text" value="<%=hdrdetails.get(14)%>" size="20"</td>
<td><input type="hidden" name="uni" id="uni" value='<%=hdrcode.get(12)%>'></td>
<%}else{%>
<td><input type="text" name="unit" id="unit" /></td>
<td><input type="hidden" name="uni" id="uni" /> </td>
<%}%>
</tr>
<tr>
</html>
Any suggestion on any above works is highly appreciated.
Thanks and regards
harshalToo much code. It's also not well intented nor formatted. I don't see a question either or it got lost in that heap of unformatted code.
I will only answer the question in the thread's subject:
How to retrieve multiple data from table and represent it in jsp pageTo retrieve, make use of HttpServletRequest#getParameterValues() and/or #getParameter().
To display, make use of JSTL's c:forEach. -
Need Help: Web Analysis, Unable to retrieve the data & Security Tab missing
Hi
I'm new to Hyperion (our version: 9.2.1) and we're implementing Hyperion Planning. One of the reporting tools is Web Analysis.
I'm trying to create simple grid reporting. but I'm unable to retrieve the data instead the result is "n/a"
and
The File's Properties > Security tab is missing
Does anyone know my issue?
Thanks,Hi Experts,
You told its resolved.how?
I am having the same issue i am unable to retrive the tables.
"Database:MS SQL Server
Driver :weblogic.jdbcx.sqlserver.SQLServerDataSource.
Connection String:jdbc:weblogic:sqlserver://localhost:1433;databaseName=BAM"
Please help if you have resolved this issue.Any helpful links plz forward [email protected]
Thanks -
How to Get Blob data(In String Form) using OCCI
Hello frnds,
I am new to OCCI,so i hvnt that much of master in that side.
I have one problem while handling BLOb data.
How to convert binary form of SDO_GEOMETRY data into string format. I am able to convert data by using PLSQL block,but its take so much time to execute.So performance is the main issue.So if there is any API in OCCI which convert directly blob data into string format.
Thanx in advance for your support,
Nilesh.Have you tried reading "http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28390/lobs.htm#BABDEGJD" ? This explains how you can read from BLOBs into a C vector (or C++ vector of chars).
Maybe you are looking for
-
Adding my Win XP-32-SP device icc/icm color profiles for dropdown PSE 10
In the printer color management I only see choices for color spaces and generic devices. I do not see my printer profiles, some custom, in the list. All are registered properly in Win color management for the the proper devices - display and printers
-
"An internal error occured" when trying to launch off the network.
Hi Gents, We are running Abobe reader 9 on a RM CC3 Network and found that when a station or laptop is not on the network you get a error when tryin to launch adobe reader. "An internal error occured" then another error box with reference to memory
-
Mac OS 1.4.11 and Nokia X3-00
My Mac is 10.4.11 and can't be upgraded to Leopard for various reasons. So I'm constrained to NMT 1.3.1 beta which doesn't recognize my Nokia X3-00. How can I transfer music between Mac and Nokia then?
-
What code can i dial to check the originality of the fone(iphone4s)
i want to buy a new iphone but there is tooo many fake ones in the market so how can i find the original one or which code can i dial to notice that.... thnak you
-
PPMDT Manager's Desktop Authorization
Hello, We have manager' desktop setup so that manager can only see employees in their own organizations. That is good. The problem is managers authorized for se16 and see info type data employees NOT in their own organizations. That is not good. Do