When i compare this constant string with MB inside with a variable with MB inside the result is false. The string constant looks like "MB" ([",M,B,"]=4 length) and my variable is "MB" ([M,B]=2 length). What's wrong here. Java cannot put the quotes inside the code into the string.
public static final String gc_TelCodeFixed = "FX";
if (!telcode.getId().equals(com.quoka.qis.db.constant.Constants.gc_TelCodeFixed))
throw new TelcodeTypeMismatchException(telcode.getType());
Invisible characters might cause this behavior.
How did the "MB" got there? did you type them or copy-paste from another program? Copy-paste operation might end up with invisible characters and text editors will not show them.
This can be easily reproduced by copying from PDF file with Linux Document Viewer.
Hope this helps, Yaron
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With