Sample SQL Commands for Database Management Professionals

Sample SQL Commands for Database Management Professionals

Kenneth Lv8

Sample SQL Commands for Database Management Professionals

Table of Contents

Disclaimer: This post includes affiliate links

If you click on a link and make a purchase, I may receive a commission at no extra cost to you.

SQL Query Examples

The SQL Query result sets can be either generic (multiple rows, multiple columns), vertical (multiple rows, 1 column) or horizontal (1 row, multiple columns).

Generic example

Assuming the following binding properties set for the SQL query:

Data Binding

The data binding set should match the query result set so in this case, we’ll have the following result set:

COL_A COL_B COL_C
ROW_1 VAL_1A VAL_1B VAL_1C
ROW_2 VAL_2A VAL_2B VAL_2C
ROW_3 VAL_3A VAL_3B VAL_3C

Results

  • any ListBox or ComboBox controls that have the associated property named COL_A_PROP will be populated withVAL_1A, VAL_2A,VAL_3A.
  • any ListBox or ComboBox controls that have the associated property named COL_B_PROP will be populated withVAL_1B, VAL_2B,VAL_3B.
  • any ListBox or ComboBox controls that have the associated property named COL_C_PROP will be populated withVAL_1C, VAL_2C,VAL_3C.
  • properties COL_A_PROP,COL_B_PROP andCOL_C_PROP will be directly set toVAL_1A, VAL_1B and respectively VAL_1C (first result set row).

NoteBefore deploying the new result set, the previous binding content will be cleared.

https://techidaily.com

Vertical example

COL_A
ROW_1 VAL_1A
ROW_2 VAL_2A
ROW_3 VAL_3A

Results

  • any ListBox or ComboBox that have the associated property namedCOL_A_PROP will be populated withVAL_1A, VAL_2A,VAL_3A.
https://techidaily.com

Horizontal example

COL_A COL_B COL_C
ROW_1 VAL_1A VAL_1B VAL_1C

Results

  • properties COL_A_PROP,COL_B_PROP andCOL_C_PROP will be directly set toVAL_1A, VAL_1B and respectively VAL_1C (first result set row).

ImportantAn empty result set is a valid output.

https://techidaily.com

Did you find this page useful?

Please give it a rating:

Thanks!

Report a problem on this page

Information is incorrect or missing

Information is unclear or confusing

Something else

Can you tell us what’s wrong?

Send message

Also read:

  • Title: Sample SQL Commands for Database Management Professionals
  • Author: Kenneth
  • Created at : 2024-10-09 16:28:46
  • Updated at : 2024-10-11 04:42:28
  • Link: https://fox-sys.techidaily.com/sample-sql-commands-for-database-management-professionals/
  • License: This work is licensed under CC BY-NC-SA 4.0.