Share via


Specifying Input Parameters for Search Conditions

For all input parameters that allow you to specify a search condition, the following two rules apply:

  • You should enclose all the property names in brackets. For example: [Country Of Origin] = N'some country' And [Name] = N‘some name'.
  • If you are using Unicode values in search phrases, then they should be preceded by a capital N. For example: [Name] = N'My name' and Description=N'some description'.

When passing values to parameters that accept a search condition, you should precede the property value by N and the property values should be enclosed in single quotes. You must do this if the values can contain Unicode characters. For example:

oCatalogManager.Search("[Name] = N'unicode_myname'")
oCatalogManager.Catalogs("[CatalogName] LIKE N'unicode_Books%'")

In the preceding example, unicode_myname and unicode_Books would be actual Unicode characters.

Copyright © 2005 Microsoft Corporation.
All rights reserved.