Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 1

Structured Query Language

Name:

The HR department of company ABC manages their staff by means


of various data tables. The following table is an excerpt for a table
named Employees. The column headings in the table correspond
to the field names in the data table.

Surname Initials Gender


Botha SG Male
Visagie P Male
Mbati DF Female
Sepeng KJ Male
Ras LG Female

1 Write two different SQL statements to list the surnames,


initials and the gender of all the employees in the data table.

2 Write a SQL statement to list the surnames and initials of all


the employees in the data table.

3 Write two different SQL statements to list the surnames,


initials and gender for all the male employees.

4 Write two different SQL statements to list the surnames,


initials and gender for all the female employees.

5 Write a SQL statement to list the surname, initials and the


gender for employee Mbati in the data table.

You might also like