Quotation Marks

Quotation Marks

Welcome to our Knowledge Base

Documentation | Blog | Demos | Support

< All Topics
Print

Quotation Marks

Quotation marks are used to delimit character strings.

Normally, the quotation marks are optional; however, quotation marks are required when

  • the string contains characters other than digits (0 to 9), letters (a to z and A to Z), the dollar sign ($), and the underscore (_)

  • the string is identical to the name of an object or command keyword

Either single or double quotation marks can be used, but the string must end with the same type of quotation mark that was used at the start, as shown in the following example:

‘This is a character string.’

“This is a character string.”

To use the same type of quotation mark as a literal character inside the string, a backslash ( – Escape) must precede it as shown in the following example:

‘This is a quotation mark (‘) inside a string.’

To reinforce the explicit use of quotation marks around character strings, you can switch the SET QUOTING command on. Then, when the software encounters an unquoted, non-numeric character string, a warning message is generated, as shown below:

Note: Character strings that are valid numbers do not elicit warnings.

Examples

If FirstName and LastName are both fields in the EntitySet Employees, and you use the command:

find Employees where LastName = Firstname

then employees with names such as John John or Leslie Leslie are sought, i.e., the employee’s last name is identical to the first name. The software makes no distinction between uppercase and lowercase letters in the names of objects.

On the other hand, if you use

find Employees where LastName = ‘Firstname’

then employees with the string Firstname in the LastName field are sought, i.e., John Firstname, Leslie Firstname, and so on.

You cannot enter the following command

find Departments where DeptName = where

because WHERE is a command keyword. The command parser sees the second instance of WHERE as being out of context and raises an error. To find a DeptName whose value is where, you must enter

find Departments where DeptName = ‘where’

Was this article helpful?
0 out of 5 stars
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
5
How can we improve this article?
Please submit the reason for your vote so that we can improve the article.

Leave a Reply

Your email address will not be published. Required fields are marked *

en_CAEnglish