Skip to Main Content
Data Analytics & Visualization All-in-One For Dummies
book

Data Analytics & Visualization All-in-One For Dummies

by Jack A. Hyman, Luca Massaron, Paul McFedries, John Paul Mueller, Lillian Pierson, Jonathan Reichental, Joseph Schmuller, Alan R. Simon, Allen G. Taylor
April 2024
Beginner content levelBeginner
832 pages
20h 32m
English
For Dummies
Content preview from Data Analytics & Visualization All-in-One For Dummies

Chapter 4

SELECT Statements and Modifying Clauses

IN THIS CHAPTER

Bullet Retrieving data from a database

Bullet Zeroing in on what you want

The main purpose of storing data on a computer is to be able to retrieve specific elements of the data when you need them. As databases grow in size, the proportion that you are likely to want on any given occasion becomes smaller. As a result, SQL provides tools that enable you to make retrievals in a variety of ways. With these tools — SELECT statements and modifying clauses — you can zero in on the precise pieces of information that you want, even though they may be buried among megabytes of data that you’re not interested in at the moment.

Finding Needles in Haystacks with the SELECT Statement

SQL’s primary tool for retrieving information from a database is the SELECT statement. In its simplest form, with one modifying clause (a FROM clause), it retrieves everything from a table. By adding more modifying clauses, you can whittle down what it retrieves until you are getting exactly what you want, no more and no less.

Suppose you want to display a complete list of all the customers in your CUSTOMER table, including every piece of data that the table stores about each one. That is the simplest retrieval you can do. Here’s the syntax:

SELECT * FROM CUSTOMER ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Data Science For Dummies

Data Science For Dummies

Lillian Pierson
Data Science For Dummies, 2nd Edition

Data Science For Dummies, 2nd Edition

Lillian Pierson, Jake Porway

Publisher Resources

ISBN: 9781394244096Purchase Link