aspose file tools*
The moose likes JDBC and the fly likes column not allowwd here - exception Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "column not allowwd here - exception" Watch "column not allowwd here - exception" New topic
Author

column not allowwd here - exception

ida jerry
Greenhorn

Joined: Mar 10, 2011
Posts: 1
Hi this is my insert statement,


"INSERT INTO CHQ_INSTRUMENT_DETAILS ( "+
"INST_REFERENCE_NO,BEN_ACCT_NO,BEN_NAME, "+
"INSTRUMENT_NO,INSTRUMENT_DATE,INSTRUMENT_AMOUNT, "+
"INSTRUMENT_CURRENCY,DRAWER_ACCT_NO,DRAWER_NAME, "+
"DRAWEE_BANK,OTHER_DRAWEE_BANK,DRAWEE_BRANCH, "+
"ABA_ROUNTING_NO,COLLECTING_COUNTRY,FD_AMOUNT, "+
"REMARKS,LINK_BRANCH_CODE, "+
"LOCATION,CL_REFERENCE_NO,STATUS, "+
"CREATED_BY, MODIFIED_BY,COLLECTING_BANK,BRANCH_REF_NO,MFX_ENTRY_DATE,MFX_REF_NO,R_RETURN_CODE,DRAWEE_BRANCH_STATE,LINK_BRANCH_NAME," +
"INST_LEVEL,FD_INST_REF_NO,ACT_STATUS,TRANSACTION_BASED,AML_BEN_NAME,bank_type,BRANCH_FLAG,CASH_LETTER_FLAG,BRANCH_REF_FORMAT,INST_AMT_INR,INSTRUMENT) "+
"VALUES ( ? ,? ,? ," +
" ? ,to_date(?, dd-mon-yy) ,? ," +
" ? ,? ,? ," +
" ? ,? ,? ," +
" ? ,? ,? ," +
" ? ,? ,? ," +
" ? ,? ,? ," +
" ? ,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)";

and this statement is throwing an exeption as below

Exception of Type 'com.sbi.gls.common.exception.SBIException' occured.
The root cause is :
org.springframework.jdbc.BadSqlGrammarException: PreparedStatementCallback; bad SQL grammar [INSERT INTO CHQ_INSTRUMENT_DETAILS ( INST_REFERENCE_NO,BEN_ACCT_NO,BEN_NAME, INSTRUMENT_NO,INSTRUMENT_DATE,INSTRUMENT_AMOUNT, INSTRUMENT_CURRENCY,DRAWER_ACCT_NO,DRAWER_NAME, DRAWEE_BANK,OTHER_DRAWEE_BANK,DRAWEE_BRANCH, ABA_ROUNTING_NO,COLLECTING_COUNTRY,FD_AMOUNT, REMARKS,LINK_BRANCH_CODE, LOCATION,CL_REFERENCE_NO,STATUS, CREATED_BY, MODIFIED_BY,COLLECTING_BANK,BRANCH_REF_NO,MFX_ENTRY_DATE,MFX_REF_NO,R_RETURN_CODE,DRAWEE_BRANCH_STATE,LINK_BRANCH_NAME,INST_LEVEL,FD_INST_REF_NO,ACT_STATUS,TRANSACTION_BASED,AML_BEN_NAME,bank_type,BRANCH_FLAG,CASH_LETTER_FLAG,BRANCH_REF_FORMAT,INST_AMT_INR,INSTRUMENT) VALUES ( ? ,? ,? , ? ,to_date(?, dd-mon-yy) ,? , ? ,? ,? , ? ,? ,? , ? ,? ,? , ? ,? ,? , ? ,? ,? , ? ,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)]; nested exception is java.sql.SQLException: ORA-00984: column not allowed here

java.sql.SQLException: ORA-00984: column not allowed here


Please help me resolve this

Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

dd-mon-yy should be 'dd-mon-yy'


[My Blog]
All roads lead to JavaRanch
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: column not allowwd here - exception