STIDistrict Query (Basic)

Similar documents
PowerPoint Presentation to Accompany GO! All In One. Chapter 13

Microsoft Access 2010

HKTA TANG HIN MEMORIAL SECONDARY SCHOOL SECONDARY 3 COMPUTER LITERACY. Name: ( ) Class: Date: Databases and Microsoft Access

Chapter 4. Microsoft Excel

Microsoft Access 2013

Microsoft Access 2013

CSC Web Programming. Introduction to SQL

Access - Introduction to Queries

Microsoft Office Illustrated. Using Tables

Creating Mailing Labels (2010)

Simply Accounting Intelligence Tips and Tricks Booklet Vol. 1

Unit 3 Fill Series, Functions, Sorting

Unit 3 Functions Review, Fill Series, Sorting, Merge & Center

Learn about the Display options Complete Review Questions and Activities Complete Training Survey

eschoolplus+ Cognos Query Studio Training Guide Version 2.4

MAS 90/200 Intelligence Tips and Tricks Booklet Vol. 1

My Query Builder Function

QUERY USER MANUAL Chapter 7

Designing Adhoc Reports

Access Intermediate

Management Reports Centre. User Guide. Emmanuel Amekuedi

Database Systems: Design, Implementation, and Management Tenth Edition. Chapter 7 Introduction to Structured Query Language (SQL)

Microsoft Access Illustrated. Unit B: Building and Using Queries

Pivot Tables, Lookup Tables and Scenarios

MIS Cases: Decision Making With Application Software, Second Edition. Database Glossary

Astra Scheduling Grids

Query Studio Training Guide Cognos 8 February 2010 DRAFT. Arkansas Public School Computer Network 101 East Capitol, Suite 101 Little Rock, AR 72201

Frequency tables Create a new Frequency Table

Unit Assessment Guide

REPORT WRITER MANUAL (Version 10)

Access Intermediate

Microsoft Office Access Learn how to use the Query window in Design view. Tutorial 3b Querying a Database

Business Insight Authoring

Welcome to Cole On-line Help system!

MASSACHUSETTS INSTITUTE OF TECHNOLOGY Sloan School of Management

Excel Tips for Compensation Practitioners Weeks Pivot Tables

Creating a Crosstab Query in Design View

Princeton University Exercise Workbook Training Developed by Elisabetta Zodeiko, Princeton University

LIBRE OFFICE CALC What is Calc? Spreadsheets, sheets, and cells spreadsheets Spreadsheets Cells

Microsoft Access 2007 Module 2

SmartView. User Guide - Analysis. Version 2.0

University of North Dakota PeopleSoft Finance Tip Sheets. Utilizing the Query Download Feature

Enforce Referential. dialog box, click to mark the. Enforce Referential. Integrity, Cascade Update Related Fields, and. Cascade Delete Related

User Guide. Web Intelligence Rich Client. Business Objects 4.1

Microsoft Excel 2010 Handout

Microsoft Access XP Queries. Student Manual

Microsoft Excel 2010

Microsoft Office Illustrated Introductory, Building and Using Queries

Open Excel by following the directions listed below: Click on Start, select Programs, and the click on Microsoft Excel.

Atlas 5.0 for Microsoft Dynamics AX Advanced reporting system.

User Manual Mail Merge

Complete Quick Reference Summary

SOFTWARE SKILLS BUILDERS

Introduction to PeopleSoft Query. The University of British Columbia

Using Microsoft Access

Relational Database Management Systems for Epidemiologists: SQL Part I

Dashboard 8.0. User Guide

Basics of Spreadsheet

USING ODBC COMPLIANT SOFTWARE MINTRAC PLUS CONTENTS:

Creating a Multi-Dimensional Report

Service Line Export and Pivot Table Report (Windows Excel 2010)

Follow these steps to get started: o Launch MS Access from your start menu. The MS Access startup panel is displayed:

How to Create Custom Name Badge Inserts with a Mail Merge in Microsoft Word 2007

Veco User Guides. Grids, Views, and Grid Reports

DESIGNING, BUILDING, AND USING DATABASES (BEGINNING MICROSOFT ACCESS, X405.4)

Exam 2 Study Guide. Denny Hood Computer Science 101

Kaseya 2. User Guide. Version 7.0. English

7. Apply a Range of Table Features

Excel Formulas & Functions I CS101

INTRODUCTION... 1 UNDERSTANDING CELLS... 2 CELL CONTENT... 4

PCB List Panel. Contents

Business Warehouse reports Running and manipulating reports. Newcastle University Andy Proctor 9 th March 2017

Ad Hoc Reporting Manual

Intermediate Excel 2016

Astra Scheduling Grids

Data. Selecting Data. Sorting Data

Intellicus Enterprise Reporting and BI Platform

Introduction to MS Excel Management Information Systems

COMP 244 DATABASE CONCEPTS & APPLICATIONS

Data Should Not be a Four Letter Word Microsoft Excel QUICK TOUR

Quick Start Guide. Version R94. English

Advanced Excel for EMIS Coordinators

Using Microsoft Access

SQL functions fit into two broad categories: Data definition language Data manipulation language

Formulas, LookUp Tables and PivotTables Prepared for Aero Controlex

Using Excel for a Gradebook: Advanced Gradebook Formulas

Microsoft Access II 1.) Opening a Saved Database Music Click the Options Enable this Content Click OK. *

Objective 1: Familiarize yourself with basic database terms and definitions. Objective 2: Familiarize yourself with the Access environment.

THE EXCEL ENVIRONMENT... 1 EDITING...

If you have questions or need assistance in any way, please contact MicroEdge Technical Support.

1. Managing Information in Table

Creating and Running a Report

Microsoft Excel. An Introduction to. Lecture No. 2. Date: March Instructor: Mr. Mustafa Babagil. Prepared By: Nima Hashemian

Using Numbers, Formulas, and Functions

Table of Contents COURSE OVERVIEW... 5

Working with Data and Charts

Reference Services Division Presents. Excel Introductory Course

EDIT202 Spreadsheet Lab Prep Sheet

Microsoft Office Excel 2007

How to stay connected. Stay connected with DIIT

Transcription:

STIDistrict Query (Basic) Creating a Basic Query To create a basic query in the Query Builder, open the STIDistrict workstation and click on Utilities Query Builder. When the program opens, database objects called Views are displayed in the top left window of the form. These views are designed to reference data in the STIDistrict database and then display the data in a way that is easier for users to understand. To expand the items listed as views, check the All Tables and Views box, located just below the views. This will allow queries to be built for any data in the STIDistrict database. To build a simple query: While in the Design screen, select a view or table from those listed at the top left. Drag and drop into the empty space to the right of the list. Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 1

Select the fields to be included in the query by checking the box to the left of each desired field description. As fields are selected, they will appear in the list at the bottom of the screen. Note: Check the first box, labeled with an asterisk (*), to select all fields in the view for output to the query. Sort the data by clicking once in the Sort Type field of the row to sort by. Then choose either Ascending or Descending order. The sort order will be determined by the value displayed in the Sort Order column. Use the Criteria column to select specific records from the database. The syntax for entering selection criteria in this field will be as follows: o = XXX: Use this formula to select only records with the value XXX in the row selected. o > XXX: Use this formula to select records with a numeric field value greater than XXX. o < XXX: Use this formula to select records with a numeric field value less than XXX. Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 2

Click on the Execute button in the toolbar at the top of the query screen to run the query. The results screen will appear, listing the found queried data in columns. Note: Click on any column label to re-sort the data by the values in that column. To make changes to the query, click on the Design tab and change the query setup as needed. Click on the Save Query button to save the query for future use. After a query has been saved, it will appear on the Query List menu in STIDistrict. Click on the Create New Query button to create a new query. Click on the Close button to close the program. Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 3

Setting Criteria Options Follow the instructions to create a basic query (see above), then perform the following steps: In the grid in the lower half of the screen, locate the field you wish to set criteria against. Follow the row across to the Criteria column. Type the criteria for the query into the cell that intersects the row for the data, and the Criteria column. The Query Builder uses Transact SQL (T-SQL) syntax rules. Examples are listed at the end of this document. Note: Use the Tab key to tab out of the Criteria field. Setting Sorting Options Follow the instructions above to create a basic query and set criteria options, then perform the following steps to sort the data: In the grid in the lower half of the screen, locate the field you wish to sort. Follow the row across to the Sort Type column. Select your sorting preference, sorting as many fields as desired. Select your sort order by adjusting the numbers in the Sort Order column. Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 4

Setting Grouping Options To set grouping options: Select the fields to query and click the button. Locate the field you wish to group. Follow the row across to the Group By column. Set your grouping options accordingly. Examples may be found in the section Aggregate Functions on page 10. Note: A very common reason for grouping records is make a count of how many records exist within each group. The example below shows a count of student records within a grouping by Grade and by Gender. Notice that the Alias column has the word Count in it, on the Student Number row. The Alias field MUST be completed for rows that contain counts. This field must also be completed for any of the grouping functions Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 5

Linking Views and/or Tables When using more than one view or table within a query, the views and/or tables will need to be linked together. Perform the following steps to do this: Locate the tables you wish to query. Find a common field between the two tables, such as Student_Number. (The STIDistrict Query (Advanced) document has examples of common joins.) Highlight the field on one of the tables. Drag and drop the field from one table to the other. Repeat these steps for any other joins to be made between the two tables. Double-click on the link between the two tables and set Join Properties accordingly. For example, if you are creating a query that uses both the Student_Demographics and Student_Attendance views, and you wish to list all students in the query even if they have no absence records in the database, you would double-click on each of the join lines between the two views and select Include all rows from qrystudent_demographics before clicking Accept. Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 6

Saving a Query To save an existing query: Click the button. Enter all desired information and click OK. o o o o o Name: Enter a name to use to identify the query. Category: Select a category from the drop-down list in which to save the query. Description: Enter a good description of what the query does. Locked: Select this option to prevent other users (who belong to other user security groups) from opening and altering the query. Private: Select this option to prevent other users (who belong to other user security groups) from opening the query at all. Opening a Saved Query To open a saved query through the STIDistrict Query Builder: Click the button. Name the query and select the category in which to save the query. (You may create new categories from within STIDistrict Workstation, under Utilities Query List.) Enter a description of the query. This description will be displayed in the header portion of the printed query. The description is therefore a useful way to communicate to the recipient of the query data exactly what sort of information the data represents. Suggested content of this area might include the user who developed the query, the criteria for data within the query, and any other information that may be helpful. Select Locked to deny anyone who does not belong to your user security group the ability to open and modify the query. Select Private to deny anyone who does not belong to your user security group the ability to open the query. Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 7

Printing and Exporting Query Results Query results may be printed or exported using the following buttons on the toolbar: Click on the Print Results button to send the data to a printer for a hard copy. In this process, the results are first displayed in a formatted report style. Click on the Print button to print these results, or click on the X (Close) button to close the report. When a report is closed, an option to export the data to a file will be presented. Select the file format in which to save the report, if desired. Note that the saved data will retain the formatting of the report. Click on the Export Results button to export the data to a file. File formats available are ASCII, HTML, and XML. Exporting data in this way saves data in columns, with no formatting. Click on the Microsoft Word button to launch the wizard to merge query results into a Word document. Click on the Microsoft Excel button to launch the wizard to merge query results into an Excel Spreadsheet. Query List To open the Query List in STIDistrict Workstation, select Utilities Query List. Queries that have been created and saved using the Query Tool will be available under this menu option. When a query is selected from the menu, the data is refreshed against the current data in the database. To print the query results, simply select the query from the list and then click the Run Query button. To edit the query, click on the Edit Query button. Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 8

Comparison Operators The following list of operators may be used for defining criteria for the data in the query. These operators would be entered into the Criteria column, with criteria as shown in the examples below. Operator Meaning = (Equal) Equal to > (Greater Than) Greater than < (Less Than) Less than >= (Greater Than or Equal To) Greater than or equal to <= (Less Than or Equal To) Less than or equal to <> (Not Equal To) Not equal to!> Not Greater Than (This is equivalent to <=)!< Not Less Than (This is equivalent to =>)!= Not Equal To (This is equivalent to =) Between BETWEEN x AND y, Inclusive selection between the supplied criteria. Comparison Operator Examples If you are trying to locate records for all students who ride bus #45, you would add the BUS_1 field to the grid and in the criteria column you would enter: =45 For students who ride on buses #45 - #50, you would add the BUS_1 field to the grid and in the criteria column for the BUS_1, you would enter: Between 45 and 50 The result of a comparison operator has the Boolean data type, which has three values: True, False and Unknown. Expressions with Boolean data types are used in the WHERE clause to filter the rows that qualify for the search conditions. Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 9

Logical Operators Logical operators test for the truth of some condition. Logical operators, like comparison operators, return a Boolean data type with a value of True or False. Operator IN LIKE NOT Meaning IN allows you to create a list of criteria (for example you would enter IN (15, 46, 99) if you were trying to find students on buses 15,46,99. LIKE is used for pattern matching. Normally it is used with the % wildcard. To use LIKE on the LNAME field you would enter LIKE MILL%, the result would return any records where the Last Name started with MILL (MILL,MILLS,MILLER) NOT Reverses the value of any other Boolean operator. Using the LIKE example above NOT LIKE MILL%, the result would return any records where the LastName DOES NOT START with MILL. Aggregate Functions Aggregate functions will be available in Daisi workstation 4.08 and higher. Aggregate functions allow you the ability to get totals of like records. Operator GROUP BY SUM MIN MAX COUNT AVG MIN DISTINCT MAX DISTINCT COUNT DISTINCT Meaning Assigns fields that must be the same to do the aggregate function. This is known as the group Creates a total within the group Finds the lowest value in the aggregate group Finds the highest value in the aggregate group Count the total number in the group Averages the field within the group The lowest of unique input values The highest of unique input values The number of unique input values Quick Reference Guide STI_1106071235 STIDistrict Query (Basic) 10