Skip to main content
Business LibreTexts

14.6: What Are Queries?

  • Page ID
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    Learning Objectives

    • Define queries in Microsoft Access
    • Create a query

    Having a database full of information is great, but it does not do the business any good if it cannot be used to make decisions. The ability to extract information from a database so that it is useful for decision-making starts with the “query.” Simply speaking, a query is a question being asked of the data to inform the business.

    A query of a database like Access gives you the ability to bring data together in a coherent manner, whether it resides in one or multiple tables. The query is the heart of “Business Intelligence” (BI) and the foundation of the Search. For example, a business may wish to know where the sales of its new product are occurring by zip code; or, who the top 5 suppliers to the business are.

    Create a Query

    Access provides query capability in the form of wizards to help create the query. To create a query, select “Create” from the tool bar and then “Query Wizard.” This will open the “New Query” window where you can choose among 4 wizards.

    Create has been selected in the toolbar and the New Query window has popped up revealing four options: Simple Query Wizard, Crosstab Query Wizard, Find Duplicates Query Wizard, and Find Unmatched Query Wizard.

    In our example, choose “Simple Query Wizard.” This wizard gives the option of choosing the table and the field for the query.

    Let’s say that we are interested in knowing the status of Purchase Orders. Since this data is distributed across 2 tables, a query is the ideal way to gather this information. For this query we will need to select the “Purchase Order” table and several fields contained there as the example below.

    We then need to add data from the “Purchase Orders Status” table, so we select that and the “Status” field as in the example below.

    Simple Query Wizard window open showing identical information to the previous image but with the field "Status" in the Selected Fields box.

    The completed query brings together the information we requested in datasheet format and from here can be sorted, edited, resized or otherwise revised.

    Complete query presents information in the form of a datasheet. The datasheet shown here includes the following information: Purchase Order ID, Supplier ID, Status ID, Submitted By, and Status.

    Contributors and Attributions

    CC licensed content, Original
    • What Are Queries?. Authored by: Robert Danielson. Provided by: Lumen Learning. License: CC BY: Attribution

    14.6: What Are Queries? is shared under a CC BY license and was authored, remixed, and/or curated by LibreTexts.

    • Was this article helpful?