Original Message:
Sent: Thu September 26, 2024 11:26 AM
From: Edward Jurczyk
Subject: JT400 Java DB2 strings vs Ecilpse strings
I believe this is true, how do you fix it?
Is there a connection statement that would fix this?
------------------------------
Edward Jurczyk
Original Message:
Sent: Wed September 25, 2024 06:18 PM
From: Scot Jenkins
Subject: JT400 Java DB2 strings vs Ecilpse strings
I have no idea what JT400 is.
Taking a guess, are the database and Java/Eclipse using the same
character set (codepage or locale)? Is one UTF and the other ASCII?
This might give you two characters that look the same but are actually
different.
As Jan mentioned, stating the OS and DB versions would be useful.
scot
Original Message:
Sent: Wed September 25, 2024 08:26 AM
From: Edward Jurczyk
Subject: JT400 Java DB2 strings vs Ecilpse strings
Sorry string are equal "3" db2, eclipse "3"
Java eclipse says they are not equal. Like I stated the work around is java contains makes it work.
Why are they not equal?
Thanks
------------------------------
Edward Jurczyk
Original Message:
Sent: Tue September 24, 2024 08:09 PM
From: Jan Nelken
Subject: JT400 Java DB2 strings vs Ecilpse strings
Hi!
Stating platform (e.g. Windows, Linux or else) and Db2 version is always helpful;
output of db2level command?
What is exact definition of Db2 table columns?
Output of db2 describe table S.T (where S is schema and T is table name)?
As for your exact question:
Why doesn't db2 strng "3" and eclipse strng "3:" match?
unless it is typo - those strings have different length and content :-)
------------------------------
Jan Nelken
Original Message:
Sent: Tue September 24, 2024 11:22 AM
From: Edward Jurczyk
Subject: JT400 Java DB2 strings vs Ecilpse strings
I have an issue with Java(JT400) strings coming from DB2 to Eclipse.
When retrieving a string from the DB2 database, into Eclipse they don't match.
I place it in debug mode the db2 string = "3" and inside eclipse string = "3".
It doesn't match, the work around is the java method contains(if(menuNumber.contains("3")))
Why doesn't db2 strng "3" and eclipse strng "3:" match?
Is it a connection issue or what?
Please help.
------------------------------
Edward Jurczyk
------------------------------