Connection Information

To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.

Connection Type

Comparing strings in DataWindow expressions – PB Docs 2021 – PowerBuilder Library

Comparing strings in DataWindow expressions – PB Docs 2021

Comparing strings in DataWindow expressions

When you compare strings, the comparison is case-sensitive.
Leading blanks are significant, but trailing blanks are not.

Case-sensitivity
examples

Assume City1 is “Austin” and City2 is “AUSTIN”. Then:

returns false.

To compare strings regardless of case, use the Upper or
Lower function. For example:

returns true.

For information about these functions, see Using DataWindow expression
functions
.

Blanks examples

Assume City1 is “Austin” and City2 is ” Austin “. Then the
expression:

returns false. PowerBuilder removes the trailing blank before
making the comparison, but it does not remove the leading
blank.

To prevent leading blanks from affecting a comparison, remove
them with one of the trim functions: Trim or LeftTrim.

For example:

returns true.

To compare strings when trailing blanks are significant, use an
expression such as the following to ensure that any trailing blanks
are included in the comparison:

For information about these functions, see Using DataWindow expression
functions
.


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x