Combining Data Sets with SQL. Advanced SAS Programming
|
|
- Alvin Young
- 7 years ago
- Views:
Transcription
1 Combining Data Sets with SQL Advanced SAS Programming
2 Joins SQL joins refer, in general, to a horizontal combination of tables: i.e.: some form of record matching. This makes SQL joins similar to merging in the data step. A very simple join
3 Simple Join proc sql create table join1 as select goals.*, performance.* from advsas.goals, advsas.performance quit The * operator selects all columns Lists tables for selection
4 Log What is the nature of the warning that we see? Merge expects (requires) variables that we join on to have the same name, SQL has no such requirement.
5 Consider proc sql create table join2 as select goals.*, performance.month as month1, performance.sales from advsas.goals, advsas.performance quit Produces no warning, and 4 variables in the resulting data set. Should also give some additional notion as to what process SQL undertook in joining these tables.
6 Cartesian Product The default joining of multiple data sets listed in the from statement is a full Cartesian product every record in one table is paired with every other. Most of the time we want a subset of that product
7 More Specific Joins One way to subset the full product is with a where statement. Select no longer chooses month from performance proc sql create table join3 as select goals.*, performance.sales from advsas.goals, advsas.performance where goals.month eq performance.month quit Subset to those that match on month
8 Final Product Result is similar to a data step merge on month
9 Inner Join This is also known as an inner join, which takes rows that match on the specified condition. proc sql create table join4 as select goals.*, performance.sales from advsas.goals join advsas.performance on goals.month eq performance.month quit On replaces where as the conditioning clause Join is used as an operator (inner is default)
10 Inner Joins vs. Data Step Merge Inner joins and data step merges are not identical. Consider proc sql create table join as select crewlist.*, sched.flightnum from advsas.crewlist, advsas.sched where crewlist.empid eq sched.empid quit versus data merge merge advsas.crewlist advsas.sched by empid run
11 Results Inner join takes matches present across all tables, merge preserves all records. We can get this behavior with merge by using the in= variable
12 Outer Joins Outer joins permit records lacking matches into the final table. proc sql create table joinfull as select crewlist.*, sched.flightnum from advsas.crewlist full join advsas.sched on crewlist.empid eq sched.empid quit Creates the same result as the previous merge.
13 Left and Right Join The left join preserves all rows from the first table listed. Hopefully the right join is selfexplanatory Consider the following joins and their results.
14 Left & Right Joins proc sql create table joinleft as select crewlist.*, sched.flightnum from advsas.crewlist left join advsas.sched on crewlist.empid eq sched.empid quit Left table had row with no match proc sql create table joinright as select crewlist.*, sched.flightnum from advsas.crewlist right join advsas.sched on crewlist.empid eq sched.empid quit Right table did not
15 One-to-Many SQL behavior is not affected by oneto-many matches. Consider a merge of the accounts and transaction tables against the possible SQL joins.
16 One to Many Merge proc sort data=advsas.accounts out=acct by account_no run proc sort data=advsas.transactions out=trans by account_no run data one_many_merge merge trans acct by account_no run
17 Inner Join proc sql create table one_many_inner as select transactions.*, fname, lname from advsas.transactions, advsas.accounts where transactions.account_no eq accounts.account_no quit
18 Full Join proc sql create table one_many_full as select transactions.*, fname, lname from advsas.transactions full join advsas.accounts on transactions.account_no eq accounts.account_no quit
19 Left Join (transactions on left) proc sql create table one_many_left as select transactions.*, fname, lname from advsas.transactions left join advsas.accounts on transactions.account_no eq accounts.account_no quit
20 Right Join (transactions on left) proc sql create table one_many_right as select transactions.*, fname, lname from advsas.transactions right join advsas.accounts on transactions.account_no eq accounts.account_no quit
21 Many-to-Many The data step does not handle many-tomany merges in what would generally be considered a useful manner. Consider the following merge: data many_to_many merge advsas.salesstaff advsas.clients by district_no run
22 Result of many-to-many data step merge (check notes in log). When multiple records have same by value in both data sets, matches one-to-one then one-to-many (see PowerPoint on merge for processing details)
23 SQL The SQL join: proc sql create table many2many as select salesstaff.*, company from advsas.salesstaff, advsas.clients where salesstaff.district_no eq clients.district_no quit
24 Result Cartesian product is formed for all records with a matching key value Is the result different for any of the outer joins?
C H A P T E R 1 Introducing Data Relationships, Techniques for Data Manipulation, and Access Methods
C H A P T E R 1 Introducing Data Relationships, Techniques for Data Manipulation, and Access Methods Overview 1 Determining Data Relationships 1 Understanding the Methods for Combining SAS Data Sets 3
More informationBeyond the Simple SAS Merge. Vanessa L. Cox, MS 1,2, and Kimberly A. Wildes, DrPH, MA, LPC, NCC 3. Cancer Center, Houston, TX. vlcox@mdanderson.
Beyond the Simple SAS Merge Vanessa L. Cox, MS 1,2, and Kimberly A. Wildes, DrPH, MA, LPC, NCC 3 1 General Internal Medicine and Ambulatory Treatment, The University of Texas MD Anderson Cancer Center,
More informationUsing DATA Step MERGE and PROC SQL JOIN to Combine SAS Datasets Dalia C. Kahane, Westat, Rockville, MD
Using DATA Step MERGE and PROC SQL JOIN to Combine SAS Datasets Dalia C. Kahane, Westat, Rockville, MD ABSTRACT This paper demonstrates important features of combining datasets in SAS. The facility to
More informationChapter 9 Joining Data from Multiple Tables. Oracle 10g: SQL
Chapter 9 Joining Data from Multiple Tables Oracle 10g: SQL Objectives Identify a Cartesian join Create an equality join using the WHERE clause Create an equality join using the JOIN keyword Create a non-equality
More informationPaper 109-25 Merges and Joins Timothy J Harrington, Trilogy Consulting Corporation
Paper 109-25 Merges and Joins Timothy J Harrington, Trilogy Consulting Corporation Abstract This paper discusses methods of joining SAS data sets. The different methods and the reasons for choosing a particular
More informationPerforming Queries Using PROC SQL (1)
SAS SQL Contents Performing queries using PROC SQL Performing advanced queries using PROC SQL Combining tables horizontally using PROC SQL Combining tables vertically using PROC SQL 2 Performing Queries
More informationa presentation by Kirk Paul Lafler SAS Consultant, Author, and Trainer E-mail: KirkLafler@cs.com
a presentation by Kirk Paul Lafler SAS Consultant, Author, and Trainer E-mail: KirkLafler@cs.com 1 Copyright Kirk Paul Lafler, 1992-2010. All rights reserved. SAS is the registered trademark of SAS Institute
More informationIntroduction to Proc SQL Steven First, Systems Seminar Consultants, Madison, WI
Paper #HW02 Introduction to Proc SQL Steven First, Systems Seminar Consultants, Madison, WI ABSTRACT PROC SQL is a powerful Base SAS Procedure that combines the functionality of DATA and PROC steps into
More informationTIM 50 - Business Information Systems
TIM 50 - Business Information Systems Lecture 15 UC Santa Cruz March 1, 2015 The Database Approach to Data Management Database: Collection of related files containing records on people, places, or things.
More informationInformation Systems SQL. Nikolaj Popov
Information Systems SQL Nikolaj Popov Research Institute for Symbolic Computation Johannes Kepler University of Linz, Austria popov@risc.uni-linz.ac.at Outline SQL Table Creation Populating and Modifying
More informationThe Query Builder: The Swiss Army Knife of SAS Enterprise Guide
Paper 1557-2014 The Query Builder: The Swiss Army Knife of SAS Enterprise Guide ABSTRACT Jennifer First-Kluge and Steven First, Systems Seminar Consultants, Inc. The SAS Enterprise Guide Query Builder
More informationKatie Minten Ronk, Steve First, David Beam Systems Seminar Consultants, Inc., Madison, WI
Paper 191-27 AN INTRODUCTION TO PROC SQL Katie Minten Ronk, Steve First, David Beam Systems Seminar Consultants, Inc., Madison, WI ABSTRACT PROC SQL is a powerful Base SAS 7 Procedure that combines the
More informationCreating Reports Crystal Clear
Creating Reports Crystal Clear Presented by: Robert Acosta - Senior Client Support Co-Presenter: Praveen Maturi - Support Manager Agenda Why Crystal Reports? Planning a Report Report Access ECD vs Company
More informationA Closer Look at PROC SQL s FEEDBACK Option Kenneth W. Borowiak, PPD, Inc., Morrisville, NC
A Closer Look at PROC SQL s FEEDBACK Option Kenneth W. Borowiak, PPD, Inc., Morrisville, NC SESUG 2012 ABSTRACT The FEEDBACK option on the PROC SQL statement controls whether an expanded or transformed
More informationChapter 1 Overview of the SQL Procedure
Chapter 1 Overview of the SQL Procedure 1.1 Features of PROC SQL...1-3 1.2 Selecting Columns and Rows...1-6 1.3 Presenting and Summarizing Data...1-17 1.4 Joining Tables...1-27 1-2 Chapter 1 Overview of
More informationIntroduction to normalization. Introduction to normalization
Introduction to normalization Lecture 4 Instructor Anna Sidorova Agenda Presentation Review of relational models, in class exersise Introduction to normalization In-class exercises Discussion of HW2 1
More information2Creating Reports: Basic Techniques. Chapter
2Chapter 2Creating Reports: Chapter Basic Techniques Just as you must first determine the appropriate connection type before accessing your data, you will also want to determine the report type best suited
More informationA Day in the Life of Data Part 2
ABSTRACT Paper 117-2013 A Day in the Life of Data Part 2 Harry Droogendyk, Stratia Consulting Inc. As a new SAS programmer, you may be overwhelmed with the variety of tricks and techniques that you see
More informationThe Essentials of Finding the Distinct, Unique, and Duplicate Values in Your Data
The Essentials of Finding the Distinct, Unique, and Duplicate Values in Your Data Carter Sevick MS, DoD Center for Deployment Health Research, San Diego, CA ABSTRACT Whether by design or by error there
More informationPaper TU_09. Proc SQL Tips and Techniques - How to get the most out of your queries
Paper TU_09 Proc SQL Tips and Techniques - How to get the most out of your queries Kevin McGowan, Constella Group, Durham, NC Brian Spruell, Constella Group, Durham, NC Abstract: Proc SQL is a powerful
More informationFoundations & Fundamentals. A PROC SQL Primer. Matt Taylor, Carolina Analytical Consulting, LLC, Charlotte, NC
A PROC SQL Primer Matt Taylor, Carolina Analytical Consulting, LLC, Charlotte, NC ABSTRACT Most SAS programmers utilize the power of the DATA step to manipulate their datasets. However, unless they pull
More informationIntroduction to SAS Mike Zdeb (402-6479, msz03@albany.edu) #122
Mike Zdeb (402-6479, msz03@albany.edu) #121 (11) COMBINING SAS DATA SETS There are a number of ways to combine SAS data sets: # concatenate - stack data sets (place one after another) # interleave - stack
More informationLab # 5. Retreiving Data from Multiple Tables. Eng. Alaa O Shama
The Islamic University of Gaza Faculty of Engineering Department of Computer Engineering ECOM 4113: Database Lab Lab # 5 Retreiving Data from Multiple Tables Eng. Alaa O Shama November, 2015 Objectives:
More information2. Conceptual Modeling using the Entity-Relationship Model
ECS-165A WQ 11 15 Contents 2. Conceptual Modeling using the Entity-Relationship Model Basic concepts: entities and entity types, attributes and keys, relationships and relationship types Entity-Relationship
More informationLecture 4: SQL Joins. Morgan C. Wang Department of Statistics University of Central Florida
Lecture 4: SQL Joins Morgan C. Wang Department of Statistics University of Central Florida 1 Outline 4.1 Introduction to SQL Joins 4.2 Complex SQL Joins 2 Outline 4.1 Introduction to SQL Joins 4.2 Complex
More informationRelational Databases
Relational Databases Jan Chomicki University at Buffalo Jan Chomicki () Relational databases 1 / 18 Relational data model Domain domain: predefined set of atomic values: integers, strings,... every attribute
More informationCIS 631 Database Management Systems Sample Final Exam
CIS 631 Database Management Systems Sample Final Exam 1. (25 points) Match the items from the left column with those in the right and place the letters in the empty slots. k 1. Single-level index files
More informationFrom The Little SAS Book, Fifth Edition. Full book available for purchase here.
From The Little SAS Book, Fifth Edition. Full book available for purchase here. Acknowledgments ix Introducing SAS Software About This Book xi What s New xiv x Chapter 1 Getting Started Using SAS Software
More informationCS 338 Join, Aggregate and Group SQL Queries
CS 338 Join, Aggregate and Group SQL Queries Bojana Bislimovska Winter 2016 Outline SQL joins Aggregate functions in SQL Grouping in SQL HAVING clause SQL Joins Specifies a table resulting from a join
More informationAn Example: Video Rental System
An Example: Video Rental System Video Rental Database Customers Rentals Videos E-R Analysis ERD Example CUSTOMER PRODUCER E-R Analysis Attributes Attribute - property or characteristic of an entity type
More informationWRITING EFFICIENT SQL. By Selene Bainum
WRITING EFFICIENT SQL By Selene Bainum About Me Extensive SQL & database development since 1995 ColdFusion Developer since 1996 Author & Speaker Co-Founder RiteTech LLC IT & Web Company in Washington,
More informationConcepts of Database Management Seventh Edition. Chapter 6 Database Design 2: Design Method
Concepts of Database Management Seventh Edition Chapter 6 Database Design 2: Design Method Objectives Discuss the general process and goals of database design Define user views and explain their function
More informationBraindumps.A00-260.54.QA
Braindumps.A00-260.54.QA Number: A00-260 Passing Score: 800 Time Limit: 120 min File Version: 14.0 http://www.gratisexam.com/ Comprehensive, easy and to the point study material made it possible for me
More informationMerging Labels, Letters, and Envelopes Word 2013
Merging Labels, Letters, and Envelopes Word 2013 Merging... 1 Types of Merges... 1 The Merging Process... 2 Labels - A Page of the Same... 2 Labels - A Blank Page... 3 Creating Custom Labels... 3 Merged
More informationReshaping & Combining Tables Unit of analysis Combining. Assignment 4. Assignment 4 continued PHPM 672/677 2/21/2016. Kum 1
Reshaping & Combining Tables Unit of analysis Combining Reshaping set: concatenate tables (stack rows) merge: link tables (attach columns) proc summary: consolidate rows proc transpose: reshape table Hye-Chung
More informationA Many to Many Merge, Without SQL? Paper TU05
A Many to Many Merge, Without SQL? Paper TU05 David Franklin Independent SAS Consultant TheProgrammersCabin.com While you are waiting, some trivia. The first U.S. Transcontinental Flight took 84 days,
More informationIntroduction to Computing. Lectured by: Dr. Pham Tran Vu t.v.pham@cse.hcmut.edu.vn
Introduction to Computing Lectured by: Dr. Pham Tran Vu t.v.pham@cse.hcmut.edu.vn Databases The Hierarchy of Data Keys and Attributes The Traditional Approach To Data Management Database A collection of
More informationRelational Division and SQL
Relational Division and SQL Soulé 1 Example Relations and Queries As a motivating example, consider the following two relations: Taken(,Course) which contains the courses that each student has completed,
More informationOutline. SAS-seminar Proc SQL, the pass-through facility. What is SQL? What is a database? What is Proc SQL? What is SQL and what is a database
Outline SAS-seminar Proc SQL, the pass-through facility How to make your data processing someone else s problem What is SQL and what is a database Quick introduction to Proc SQL The pass-through facility
More informationDatabase Administration with MySQL
Database Administration with MySQL Suitable For: Database administrators and system administrators who need to manage MySQL based services. Prerequisites: Practical knowledge of SQL Some knowledge of relational
More informationKen Goldberg Database Lab Notes. There are three types of relationships: One-to-One (1:1) One-to-Many (1:N) Many-to-Many (M:N).
Lab 3 Relationships in ER Diagram and Relationships in MS Access MS Access Lab 3 Summary Introduction to Relationships Why Define Relationships? Relationships in ER Diagram vs. Relationships in MS Access
More informationSQL Server. 1. What is RDBMS?
SQL Server 1. What is RDBMS? Relational Data Base Management Systems (RDBMS) are database management systems that maintain data records and indices in tables. Relationships may be created and maintained
More informationMOC 20461C: Querying Microsoft SQL Server. Course Overview
MOC 20461C: Querying Microsoft SQL Server Course Overview This course provides students with the knowledge and skills to query Microsoft SQL Server. Students will learn about T-SQL querying, SQL Server
More informationEXST SAS Lab Lab #4: Data input and dataset modifications
EXST SAS Lab Lab #4: Data input and dataset modifications Objectives 1. Import an EXCEL dataset. 2. Infile an external dataset (CSV file) 3. Concatenate two datasets into one 4. The PLOT statement will
More informationTopic: Relationships in ER Diagram and Relationships in MS Access
MS Access Lab 3 Topic: Relationships in ER Diagram and Relationships in MS Access Summary Introduction to Relationships Why Define Relationships? Relationships in ER Diagram vs. Relationships in MS Access
More informationPractical Database Design
Today s discussion Practical Design In a research environment Kim Laursen, ITS Education Coordinator, 9-5674 Tom Reardon, ITS Senior Programmer/Analyst, 9-5671 What is a database? Steps in designing a
More informationThe Apache Cassandra storage engine
The Apache Cassandra storage engine Sylvain Lebresne (sylvain@.com) FOSDEM 12, Brussels 1. What is Apache Cassandra 2. Data Model 3. The storage engine 1. What is Apache Cassandra 2. Data Model 3. The
More information9.1 SAS. SQL Query Window. User s Guide
SAS 9.1 SQL Query Window User s Guide The correct bibliographic citation for this manual is as follows: SAS Institute Inc. 2004. SAS 9.1 SQL Query Window User s Guide. Cary, NC: SAS Institute Inc. SAS
More informationUsing SQL Joins to Perform Fuzzy Matches on Multiple Identifiers Jedediah J. Teres, MDRC, New York, NY
Using SQL Joins to Perform Fuzzy Matches on Multiple Identifiers Jedediah J. Teres, MDRC, New York, NY ABSTRACT Matching observations from different data sources is problematic without a reliable shared
More informationAdvanced Subqueries In PROC SQL
Advanced Subqueries In PROC SQL PROC SQL; SELECT STATE, AVG(SALES) AS AVGSALES FROM USSALES GROUP BY STATE HAVING AVG(SALES) > (SELECT AVG(SALES) FROM USSALES); QUIT; STATE AVGSALES --------------- IL
More information12.1 Nested Relational Prototype Operation
(from the book Advanced ANSI SQL Data Modeling and Structure Processing by Michael M David, published and copyrighted 1999 by Artech-House Publishers) The examples in this chapter show the operation of
More informationImproving Maintenance and Performance of SQL queries
PaperCC06 Improving Maintenance and Performance of SQL queries Bas van Bakel, OCS Consulting, Rosmalen, The Netherlands Rick Pagie, OCS Consulting, Rosmalen, The Netherlands ABSTRACT Almost all programmers
More informationDiving into SAS Software with the SQL Procedure Kirk Paul Lafler, Software Intelligence Corporatron
Diving into SAS Software with the SQL Procedure Kirk Paul Lafler, Software ntelligence Corporatron ABSTRACT Joining two or more tables of data is a powerful feature found in the relational model and the
More informationMS Access. Microsoft Access is a relational database management system for windows. Using this package, following tasks can be performed.
MS Access Microsoft Access is a relational database management system for windows. Using this package, following tasks can be performed. Organize data into manageable related units Enter, modify and locate
More informationSQL SUBQUERIES: Usage in Clinical Programming. Pavan Vemuri, PPD, Morrisville, NC
PharmaSUG 2013 Poster # P015 SQL SUBQUERIES: Usage in Clinical Programming Pavan Vemuri, PPD, Morrisville, NC ABSTRACT A feature of PROC SQL which provides flexibility to SAS users is that of a SUBQUERY.
More informationMigrating from Sybase to SQL Server
Migrating from to Table of Contents: Migrating from to Data Compatibility Mode Behavior Optimizer Hints Conclusion Migrating from to Projects involving database migration are common. In this article, we
More informationJoin Example. Join Example Cart Prod. www.comp-soln.com 2006 Comprehensive Consulting Solutions, Inc.All rights reserved.
Join Example S04.5 Join Example Cart Prod S04.6 Previous joins are equijoins (=) Other operators can be used e.g. List all my employees older than their manager SELECT emp.name FROM employee emp, manager
More informationEffective Use of SQL in SAS Programming
INTRODUCTION Effective Use of SQL in SAS Programming Yi Zhao Merck & Co. Inc., Upper Gwynedd, Pennsylvania Structured Query Language (SQL) is a data manipulation tool of which many SAS programmers are
More informationMail Merge Microsoft Word and Excel Queries Scott Kern Senior Consultant
Mail Merge Microsoft Word and Excel Queries Scott Kern Senior Consultant What We ll Cover 1. Enabling database connections through Microsoft Excel 2. Accessing the data stored in the SQL Database via the
More informationSpring,2015. Apache Hive BY NATIA MAMAIASHVILI, LASHA AMASHUKELI & ALEKO CHAKHVASHVILI SUPERVAIZOR: PROF. NODAR MOMTSELIDZE
Spring,2015 Apache Hive BY NATIA MAMAIASHVILI, LASHA AMASHUKELI & ALEKO CHAKHVASHVILI SUPERVAIZOR: PROF. NODAR MOMTSELIDZE Contents: Briefly About Big Data Management What is hive? Hive Architecture Working
More informationSQL Server Replication Guide
SQL Server Replication Guide Rev: 2013-08-08 Sitecore CMS 6.3 and Later SQL Server Replication Guide Table of Contents Chapter 1 SQL Server Replication Guide... 3 1.1 SQL Server Replication Overview...
More informationDemystifying PROC SQL Join Algorithms Kirk Paul Lafler, Software Intelligence Corporation
Paper TU01 Demystifying PROC SQL Join Algorithms Kirk Paul Lafler, Software Intelligence Corporation ABSTRACT When it comes to performing PROC SQL joins, users supply the names of the tables for joining
More informationPhysical Database Design Process. Physical Database Design Process. Major Inputs to Physical Database. Components of Physical Database Design
Physical Database Design Process Physical Database Design Process The last stage of the database design process. A process of mapping the logical database structure developed in previous stages into internal
More information9 CREATING REPORTS WITH REPORT WIZARD AND REPORT DESIGNER
9 CREATING REPORTS WITH REPORT WIZARD AND REPORT DESIGNER 9.1 INTRODUCTION Till now you have learned about creating Table, Query and Form using the respective Wizard and Designer mode. Every application
More informationCrystal Reports Form Letters Replace database exports and Word mail merges with Crystal's powerful form letter capabilities.
Crystal Reports Form Letters Replace database exports and Word mail merges with Crystal's powerful form letter capabilities. Prerequisites: Fundamental understanding of conditional formatting formulas
More informationAn Introduction to Excel Pivot Tables
An Introduction to Excel Pivot Tables EXCEL REVIEW 2001-2002 This brief introduction to Excel Pivot Tables addresses the English version of MS Excel 2000. Microsoft revised the Pivot Tables feature with
More informationAlternatives to Merging SAS Data Sets But Be Careful
lternatives to Merging SS Data Sets ut e Careful Michael J. Wieczkowski, IMS HELTH, Plymouth Meeting, P bstract The MERGE statement in the SS programming language is a very useful tool in combining or
More informationCounting the Ways to Count in SAS. Imelda C. Go, South Carolina Department of Education, Columbia, SC
Paper CC 14 Counting the Ways to Count in SAS Imelda C. Go, South Carolina Department of Education, Columbia, SC ABSTRACT This paper first takes the reader through a progression of ways to count in SAS.
More informationOracle Database 10g: Introduction to SQL
Oracle University Contact Us: 1.800.529.0165 Oracle Database 10g: Introduction to SQL Duration: 5 Days What you will learn This course offers students an introduction to Oracle Database 10g database technology.
More informationPROC SQL. Beyond the Basics Using SAS Second Edition. Kirk Paul Lafler
PROC SQL Beyond the Basics Using SAS Second Edition Kirk Paul Lafler From PROC SQL, Second Edition. Full book available for purchase here. Contents About This Book...xv About The Author... xix Acknowledgments...
More informationAdvanced Tornado TWENTYONE. 21.1 Advanced Tornado. 21.2 Accessing MySQL from Python LAB
21.1 Advanced Tornado Advanced Tornado One of the main reasons we might want to use a web framework like Tornado is that they hide a lot of the boilerplate stuff that we don t really care about, like escaping
More informationChapter 9, More SQL: Assertions, Views, and Programming Techniques
Chapter 9, More SQL: Assertions, Views, and Programming Techniques 9.2 Embedded SQL SQL statements can be embedded in a general purpose programming language, such as C, C++, COBOL,... 9.2.1 Retrieving
More informationUsing Multiple Operations. Implementing Table Operations Using Structured Query Language (SQL)
Copyright 2000-2001, University of Washington Using Multiple Operations Implementing Table Operations Using Structured Query Language (SQL) The implementation of table operations in relational database
More informationThe Online Research Database Service (ORDS)
The Online Research Database Service (ORDS) Monday, 2 nd November, 2015 Dr James A J Wilson & Dr Meriel Patrick ords@it.ox.ac.uk What is the ORDS? Online Research Database Service Simple online database
More informationAccess Part 2 - Design
Access Part 2 - Design The Database Design Process It is important to remember that creating a database is an iterative process. After the database is created and you and others begin to use it there will
More informationBridge from Entity Relationship modeling to creating SQL databases, tables, & relations
1 Topics for this week: 1. Good Design 2. Functional Dependencies 3. Normalization Readings for this week: 1. E&N, Ch. 10.1-10.6; 12.2 2. Quickstart, Ch. 3 3. Complete the tutorial at http://sqlcourse2.com/
More informationTable 1. Demog. id education B002 5 b003 8 b005 5 b007 9 b008 7 b009 8 b010 8
Adding PROC SQL to your SAS toolbox for merging multiple tables without common variable names Susan Wancewicz, Moores Cancer Center, UCSD, La Jolla, CA ABSTRACT The SQL procedure offers an efficient method
More information2874CD1EssentialSQL.qxd 6/25/01 3:06 PM Page 1 Essential SQL Copyright 2001 SYBEX, Inc., Alameda, CA www.sybex.com
Essential SQL 2 Essential SQL This bonus chapter is provided with Mastering Delphi 6. It is a basic introduction to SQL to accompany Chapter 14, Client/Server Programming. RDBMS packages are generally
More informationICAB4136B Use structured query language to create database structures and manipulate data
ICAB4136B Use structured query language to create database structures and manipulate data Release: 1 ICAB4136B Use structured query language to create database structures and manipulate data Modification
More informationGuide to Performance and Tuning: Query Performance and Sampled Selectivity
Guide to Performance and Tuning: Query Performance and Sampled Selectivity A feature of Oracle Rdb By Claude Proteau Oracle Rdb Relational Technology Group Oracle Corporation 1 Oracle Rdb Journal Sampled
More informationJoining Tables in Access
Joining Tables in Access Quite often, you ll get data from a government agency that is stored in separate tables. They do that in order to save space, which was a much bigger necessity when government
More informationRelational model. Relational model - practice. Relational Database Definitions 9/27/11. Relational model. Relational Database: Terminology
COS 597A: Principles of Database and Information Systems elational model elational model A formal (mathematical) model to represent objects (data/information), relationships between objects Constraints
More informationDatabases What the Specification Says
Databases What the Specification Says Describe flat files and relational databases, explaining the differences between them; Design a simple relational database to the third normal form (3NF), using entityrelationship
More informationMastering Mail Merge. 2 Parts to a Mail Merge. Mail Merge Mailings Ribbon. Mailings Create Envelopes or Labels
2 Parts to a Mail Merge 1. MS Word Document (Letter, Labels, Envelope, Name Badge, etc) 2. Data Source Excel Spreadsheet Access Database / query Other databases (SQL Server / Oracle) Type in New List Mail
More informationIntroduction to Proc SQL Katie Minten Ronk, Systems Seminar Consultants, Madison, WI
Paper 268-29 Introduction to Proc SQL Katie Minten Ronk, Systems Seminar Consultants, Madison, WI ABSTRACT PROC SQL is a powerful Base SAS Procedure that combines the functionality of DATA and PROC steps
More informationHansaWorld SQL Training Material
HansaWorld University HansaWorld SQL Training Material HansaWorld Ltd. January 2008 Version 5.4 TABLE OF CONTENTS: TABLE OF CONTENTS:...2 OBJECTIVES...4 INTRODUCTION...5 Relational Databases...5 Definition...5
More informationIntroduction to SQL and SQL in R. LISA Short Courses Xinran Hu
Introduction to SQL and SQL in R LISA Short Courses Xinran Hu 1 Laboratory for Interdisciplinary Statistical Analysis LISA helps VT researchers benefit from the use of Statistics Collaboration: Visit our
More informationLecture 25: Database Notes
Lecture 25: Database Notes 36-350, Fall 2014 12 November 2014 The examples here use http://www.stat.cmu.edu/~cshalizi/statcomp/ 14/lectures/23/baseball.db, which is derived from Lahman s baseball database
More informationAdministering a Microsoft SQL Server 2000 Database
Aug/12/2002 Page 1 of 5 Administering a Microsoft SQL Server 2000 Database Catalog No: RS-MOC2072 MOC Course Number: 2072 5 days Tuition: $2,070 Introduction This course provides students with the knowledge
More informationPaper 70-27 An Introduction to SAS PROC SQL Timothy J Harrington, Venturi Partners Consulting, Waukegan, Illinois
Paper 70-27 An Introduction to SAS PROC SQL Timothy J Harrington, Venturi Partners Consulting, Waukegan, Illinois Abstract This paper introduces SAS users with at least a basic understanding of SAS data
More informationBusiness Portal for Microsoft Dynamics GP 2010. User s Guide Release 5.1
Business Portal for Microsoft Dynamics GP 2010 User s Guide Release 5.1 Copyright Copyright 2011 Microsoft. All rights reserved. Limitation of liability This document is provided as-is. Information and
More informationThe Relational Algebra
The Relational Algebra Relational set operators: The data in relational tables are of limited value unless the data can be manipulated to generate useful information. Relational Algebra defines the theoretical
More informationDatabase Design for the Uninitiated CDS Brownbag Series CDS
Database Design for the Uninitiated Paul Litwin FHCRC Collaborative Data Services 1 CDS Brownbag Series This is the ninth in a series of seminars Materials for the series can be downloaded from www.deeptraining.com/fhcrc
More informationAVOIDANCE OF CYCLICAL REFERENCE OF FOREIGN KEYS IN DATA MODELING USING THE ENTITY-RELATIONSHIP MODEL
AVOIDANCE OF CYCLICAL REFERENCE OF FOREIGN KEYS IN DATA MODELING USING THE ENTITY-RELATIONSHIP MODEL Ben B. Kim, Seattle University, bkim@seattleu.edu ABSTRACT The entity-relationship (ER model is clearly
More informationTutorial: How to Use SQL Server Management Studio from Home
Tutorial: How to Use SQL Server Management Studio from Home Steps: 1. Assess the Environment 2. Set up the Environment 3. Download Microsoft SQL Server Express Edition 4. Install Microsoft SQL Server Express
More informationChapter 5 More SQL: Complex Queries, Triggers, Views, and Schema Modification
Chapter 5 More SQL: Complex Queries, Triggers, Views, and Schema Modification Copyright 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 5 Outline More Complex SQL Retrieval Queries
More informationSUBQUERIES AND VIEWS. CS121: Introduction to Relational Database Systems Fall 2015 Lecture 6
SUBQUERIES AND VIEWS CS121: Introduction to Relational Database Systems Fall 2015 Lecture 6 String Comparisons and GROUP BY 2! Last time, introduced many advanced features of SQL, including GROUP BY! Recall:
More informationBig Data, Fast Processing Speeds Kevin McGowan SAS Solutions on Demand, Cary NC
Big Data, Fast Processing Speeds Kevin McGowan SAS Solutions on Demand, Cary NC ABSTRACT As data sets continue to grow, it is important for programs to be written very efficiently to make sure no time
More informationDATA Step versus PROC SQL Programming Techniques
Paper FF-003 DATA Step versus PROC SQL Programming Techniques Kirk Paul Lafler, Software Intelligence Corporation ABSTRACT Are you considering whether to use a DATA step or PROC SQL step in your next project?
More information