Differences in Delimit Characters

The previous examples used square brackets ( [ ] ) as delimit characters, a very common implementation. However, other, equally common delimit characters exist, and some that are not so common. A consumer cannot rely on any particular delimit character if working with multiple data sources but should check for a provider’s quotation characters. This ensures interoperability.

The OLE DB method IDBInfo::GetLiteralInfo provides a way a consumer can interrogate the provider to find the delimit character. The consumer should use DBLITERAL = DBLITERAL_QUOTE. In the returned DBLITERALINFO structure, the pwszLiteralValue column contains the delimit characters.

If it contains just one character, then the same character is used at both ends of the delimited identifier. A common example is the double quotation mark ("), which is used as "USA"."New Jersey"."New Albany". If it contains two characters, then the first character begins the delimited identifier and the second character terminates it. The double bracket characters are an example of this.