When retrieving data, you may want to set up a filtering expression or relation between tables. You can do it using WHERE and HAVING clauses. Refer to SQL manual to learn what’s different in these sections. In dbForge Studio visual interface for WHERE and HAVING clauses is the same.
In the tabbed editor conditions are displayed as a tree with condition and group nodes. A group consists of several conditions or subgroups, united with a logical operator. You can change a group logical operator by clicking it and selecting another one from the menu. To navigate between conditions and groups, use the UP ARROW and DOWN ARROW keys. Use the LEFT ARROW and RIGHT ARROW keys to navigate between criteria operator and operands.
To create a new group, do one of the following:
Click the upper-level group operator and choose Add Group on the menu that appears.
Press CTRL+PLUS SIGN.
To create a new condition, do the following:
To remove a condition, click the condition button or navigate to condition and press DELETE or MINUS SIGN key. To remove a group click its logical operator and choose Remove Group from the appeared menu or navigate to the group and press DELETE or MINUS SIGN key.
You also can copy, cut, and paste conditions and groups with CTRL+C, CTRL+X, and CTRL+V keys.
The following clause is generated according to the sample image:
WHERE Product.Color = 'silver' AND ProductCategory.Name >= 'components'