Documentation Center

Storage Layer Global/MetaQueryConstants section

The MetaQueryConstants section in the Global section of the Storage Layer configuration file, cd_storage_conf.xml, configures constants used in querying. You only need to change this section if you use the findByURL() or findByPageURL() method in your code, and if you're experiencing case sensitivity issues.

This section has one child element, FindByUrlCaseSensitivity. This setting needs to be changed only under the following exceptional circumstances:
  • You use the findByURL() or findByPageURL() method in your code.
  • The default setting for case sensitivity as listed below is incorrect for your implementation.
Two interfaces in the public Broker API (and all classes that implement them) have a method called findByURL() or findByPageURL(). They are:
  • com.tridion.storage.dao.BinaryVariantDAO
  • com.tridion.storage.dao.ItemDAO

Calling the findByURL() or findByPageURL() method on a class that implements one of these interfaces is one way of retrieving a Page or a binary by way of a URL lookup. Depending on the storage medium you use, the URL lookup of a page or binary by the Content Broker may fail because the lookup is case-sensitive.

For example, when a page is stored on the Windows file system as mypage.html and when IIS is used as a web and application server, accessing the URL MyPage.html will retrieve the page, as will a call to findByPageURL(). However, when using Tomcat as a web and application server, Tomcat would not serve the page (because Tomcat is case-sensitive), but findByPageURL() would successfully retrieve the page. This leads to inconsistent behavior.

To solve this problem, you can configure the case sensitivity of the findByURL() or findByPageURL() method in the current element. Only the UNIX file system remains unaffected by this setting.

The following overviews shows for each storage medium how the value of the current element (or the absence of a value) affects the case sensitivity of the URL lookup:
Storage systemEffect of setting
SQL Server databaseCase-sensitive only if case-sensitivity is explicitly set to true
Oracle databaseCase-sensitive only if case-sensitivity is explicitly set to true
Windows file systemCase-sensitive only if case-sensitivity is explicitly set to true
UNIX file systemAlways case-sensitive, the setting is ignored
For example, the following text makes URL lookup on the Windows operating system case-sensitive:
<MetaQueryConstants><FindByURLCaseSensitivity Value="true" /></MetaQueryConstants>