Welcome to B:bob:B!
As you have found out, you cannot use any sort of function or comparison other than = in a Where clause in a Variable. There is a FAQ entry that discusses one possible solution.
There are also a number of different examples of variable “where” clauses in some of the presentations that I’ve done over the years… you can download them all here:
http://www.integrasolutions.net/isi_library_presentations.htm
Dave Rathbun (BOB member since 2002-06-06)