aspose file tools*
The moose likes JDBC and the fly likes VARCHAR2 TO CHAR - not records returned. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "VARCHAR2 TO CHAR - not records returned." Watch "VARCHAR2 TO CHAR - not records returned." New topic
Author

VARCHAR2 TO CHAR - not records returned.

Prasad Potla
Greenhorn

Joined: Nov 07, 2003
Posts: 3
Hi All,

I changed a oracle table column types from varchar2 to char for making the job of other teams easy since they have legacy systems.

I was using the prepared statements to query on the table and was using setString(1,pnum) to pass the part number as parameter. After the varchar2 to char change prepared statements stopped working.

If I query on the table with statement, it is working. [ I was appending the pnum as in the string to make to work].

Did anyone experienced this kind of problem, or if anyone know the solution for this problem. Please let me know.

Thanks
P
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18570
    
    8

"pr po", welcome to JavaRanch.

We're a friendly group here, but we do require members to have valid display names.

Display names must contain your first name, a space, then your last name. Fictitious names are not allowed.

Please edit your profile and correct your display name since accounts with invalid display names will be deleted.

And, after you do that, could you explain further what "working" and "not working" mean in relation to your problem?
Prasad Potla
Greenhorn

Joined: Nov 07, 2003
Posts: 3
Originally posted by Pr Po:
Hi All,

I changed a oracle table column types from varchar2 to char for making the job of other teams easy since they have legacy systems.

I was using the prepared statements to query on the table and was using setString(1,pnum) to pass the part number as parameter. After the varchar2 to char change prepared statements stopped working.

If I query on the table with statement, it is working. [ I was appending the pnum as in the string to make to work].

Did anyone experienced this kind of problem, or if anyone know the solution for this problem. Please let me know.

Thanks
P
Prasad Potla
Greenhorn

Joined: Nov 07, 2003
Posts: 3
I solved the problem by changing the driver.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: VARCHAR2 TO CHAR - not records returned.