100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached
logo-home
A Guide to SQL - Microsoft Access R125,00   Add to cart

Interview

A Guide to SQL - Microsoft Access

1 review
 100 views  1 purchase
  • Institution
  • 11

A comprehensive summary of SQL content at a Grade 11 Level. It contains all the necessary information in a colourful, table format. Diagrams of complex topics have been included. All information has been typed for improved legibility.

Last document update: 3 year ago

Preview 2 out of 12  pages

  • October 24, 2021
  • October 25, 2021
  • 12
  • 2022/2023
  • Interview
  • Unknown
  • Unknown
book image

Book Title:

Author(s):

  • Edition:
  • ISBN:
  • Edition:
All documents for this subject (11)

1  review

review-writer-avatar

By: ethanfredyt • 1 month ago

avatar-seller
Zeyni
2




1. Extracting Data from the Whole Table



SELECT *
FROM <tableName>


SELECT Extracts data from the table

* All fields for that record - wildcard

FROM From the specified table




SELECT *
FROM <tableName>
ORDER BY <field1> ( ASC / DESC ), … <fieldn> ( ASC / DESC )


ORDER BY Orders selected fields only, in order of the fields entered (field1 before field2)

ASC Ascending

DESC Descending




SELECT TOP <n> * // MS ACCESS will return all rows with that value
FROM <tableName>
ORDER BY <field1> ( ASC / DESC ), … <fieldn> ( ASC / DESC )


TOP <n> ● Limit the number of rows displayed in a table
● TOP 1 can be used to find the largest / smallest, as it limits the result to one record




2

, 3




2. Limiting The Fields



SELECT <field1>, … <fieldn>
FROM <tableName>

<field1>, … <fieldn> Which fields are displayed and in what order




SELECT DISTINCT <field1>, … <fieldn>
FROM <tableName>

DISTINCT Fetch unique rows based on the fields selected, ignoring duplicates




3. Calculations



SELECT <field1>, … <fieldn>, <calculations>
FROM <tableName>

<calculations> The result set will display the listed fields as columns and a new column for
each calculation

The new column is given a random name e.g. ‘Expr1005’




SELECT <field1>, … <fieldn>, <calculations> AS [name]
FROM <tableName>

AS [name] Specifies the name for the column

Use square brackets for 3 words or more, or if the name includes keywords e.g. BY
Can also use CamelCase




3

The benefits of buying summaries with Stuvia:

Guaranteed quality through customer reviews

Guaranteed quality through customer reviews

Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.

Quick and easy check-out

Quick and easy check-out

You can quickly pay through EFT, credit card or Stuvia-credit for the summaries. There is no membership needed.

Focus on what matters

Focus on what matters

Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!

Frequently asked questions

What do I get when I buy this document?

You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.

Satisfaction guarantee: how does it work?

Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.

Who am I buying this summary from?

Stuvia is a marketplace, so you are not buying this document from us, but from seller Zeyni. Stuvia facilitates payment to the seller.

Will I be stuck with a subscription?

No, you only buy this summary for R125,00. You're not tied to anything after your purchase.

Can Stuvia be trusted?

4.6 stars on Google & Trustpilot (+1000 reviews)

67096 documents were sold in the last 30 days

Founded in 2010, the go-to place to buy summaries for 14 years now

Start selling
R125,00  1x  sold
  • (1)
  Buy now