This week's book giveaway is in the Design forum.
We're giving away four copies of Building Microservices and have Sam Newman on-line!
See this thread for details.
The moose likes JDBC and Relational Databases and the fly likes Error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Building Microservices this week in the Design forum!
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Error" Watch "Error" New topic
Author

Error

Red Rose
Greenhorn

Joined: Dec 28, 2011
Posts: 4


Hi Team,


While executing above program i am getting following error, kindly help me to clear that error

java.sql.SQLException: [Oracle][ODBC][Ora]ORA-00907: missing right parenthesis
java.sql.SQLException: [Oracle][ODBC][Ora]ORA-00907: missing right parenthesis
at sun.jdbc.odbc.JdbcOdbc.createSQLException(JdbcOdbc.java:6956)
at sun.jdbc.odbc.JdbcOdbc.standardError(JdbcOdbc.java:7113)
at sun.jdbc.odbc.JdbcOdbc.SQLExecDirect(JdbcOdbc.java:3109)
at sun.jdbc.odbc.JdbcOdbcStatement.execute(JdbcOdbcStatement.java:337)
at sun.jdbc.odbc.JdbcOdbcStatement.executeQuery(JdbcOdbcStatement.java:252)
at database.CreateTable.main(CreateTable.java:23)
BUILD SUCCESSFUL (total time: 0 seconds)
Martin Vajsar
Sheriff

Joined: Aug 22, 2010
Posts: 3718
    
  61

Welcome to the Ranch!

First of all, do not use ODBC. Use Oracle's JDBC driver, it performs better and is more supported.

Anyway, your error has nothing to do with Java. Try running the statement in SQL*Plus or something similar, you'll get the same error message. The problem is that the INT type in Oracle is a synonym for NUMBER(38) and cannot take any precision. You probably wanted to use NUMBER(20) instead.
 
Have you checked out Aspose?
 
subject: Error
 
It's not a secret anymore!