like pattern matching

Adaptive Server version allows you to treat square brackets individually in the like pattern-matching algorithm.

For example, matching a row with ‘[XX]’ in earlier versions of Adaptive Server required you to use:

select * from t1 where f1 like '[[]XX[]]'

However, you can also use:

select * from t1 where f1 like '[[]XX]'

When you use like pattern-matching:

The patterns and matches for like pattern-matching are:

Pattern

Matches

[[]

[

[]]

]

]

]

[[]XX]

[XX]

[[]XX[]]

[XX]