• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

VARCHAR2 TO CHAR - not records returned.

 
Prasad Potla
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Sheriff
Posts: 21548
33
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"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
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I solved the problem by changing the driver.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic