Forum Discussion
Philip_Baird
11 years agoCommunity Expert
Hi Vijay, I am assuming by "java" you mean JScript.
If so, be aware that JScript has two equality and inequality operators
== and ===
!= and !==
== and != employ type coersion, i.e. if the operands are of a different type, the JScript runtime will coerce one of the operands so it can perform the operation, e.g.
Log.Message( 11 == "11" ); // Logs true
This can lead to unexpected results, whereas === and !== do NOT employ type coersion and will always evaluate correctly e.g.
Log.Message( 11 === "11" ); // Logs false
I mention this as you appear to be dealing with alphanumerics from a csv file where this may come into play
Regards,
Phil Baird
If so, be aware that JScript has two equality and inequality operators
== and ===
!= and !==
== and != employ type coersion, i.e. if the operands are of a different type, the JScript runtime will coerce one of the operands so it can perform the operation, e.g.
Log.Message( 11 == "11" ); // Logs true
This can lead to unexpected results, whereas === and !== do NOT employ type coersion and will always evaluate correctly e.g.
Log.Message( 11 === "11" ); // Logs false
I mention this as you appear to be dealing with alphanumerics from a csv file where this may come into play
Regards,
Phil Baird
Related Content
Recent Discussions
- 2 days agoMW_Didata