Chapter 9 Transact-SQL This Chapter Introduces the Many Options

Total Page:16

File Type:pdf, Size:1020Kb

Chapter 9 Transact-SQL This Chapter Introduces the Many Options Transact-SQL Page 1 of 53 Chapter 9 Transact-SQL This chapter introduces the many options available for working with the SQL query language, along with the extensions and special features of Microsoft SQL Server/MSDE’s SQL dialect. The SQL standard was developed by the American National Standards Institute (ANSI) and the International Organization for Standardization (ISO). Today there are several standards whose names include the year in which they were released: SQL-89, SQL-92, and so on. The different standards vary in language functions and performance. Database vendors have fully or partially implemented the SQL standards in their products. Unfortunately, they have not yet agreed on a unified standard. Almost all have added their own extensions to the SQL implementations, so there are some significant differences among the SQL variations of individual products. Microsoft Access 2000 and Microsoft Access 2002 use Jet Engine 3.6—the database core for Access mdb databases—to support SQL-89 Level 1 with several extensions, as well as SQL-92 (albeit not completely) if you are using Jet Engine 4 with the ADO database interface. SQL Server/MSDE supports SQL-92, which for the most part conforms to the ANSI/ISO standard. The SQL language functions consist of two parts: The Data Definition Language (DDL) and the Data Manipulation Language (DML). With DDL, you can create, edit, and delete table structures and define indexes. The DML is used to query data or to edit and delete data. In Access, you usually only work with the DML, as tables and indexes are created with the tools available in Access. Access mdb users rarely have to deal with SQL directly because the Access user interface makes it possible to create queries interactively, and it then generates the actual SQL command itself. In Access projects, you can interactively create SQL commands for views only with the View Designer. All other commands in stored procedures must be entered manually, directly in SQL. You can use the Access support functions for .mdb files when creating SQL commands for your Access projects, as well. Simply create an .mdb file in parallel with your Access project, and then use the file to define table links for the tables on SQL Server/MSDE (select File, then Get External Data, then Link Tables). If you then create new queries, you can select View, then SQL in Design mode to view the SQL commands that the query you created is based on. Copy the SQL text to the Windows Clipboard and then paste it into a stored procedure, for example, in the Access project. Note that character strings in Access mdb databases are delineated by double quotation marks, whereas SQL Server/MSDE uses single quotation marks. Access mdb databases let you test SQL queries without first saving the query in the mdb database. By contrast, in Access projects, you must first save a query (with views as well as with stored procedures) before implementing it. You must do this in Access projects because saving the query transmits it to SQL Server/MSDE, which also checks the query to make sure the syntax is correct. If you want to perform ad hoc tests of your queries, you can use the frmSQL form, which is covered in Chapter 14, “Command Objects.” You can also use the SQL Server Query Analyzer (see Chapter 19, “SQL Server Tools”) if you are using SQL Server and not just MSDE. file://C:\Documents%20and%20Settings\richard.welke.ECI\Local%20Settings\Temp\~hh8... 3/21/2004 Transact-SQL Page 2 of 53 Select Queries with SELECT SELECT is the most important and most frequently used SQL command. It initiates select queries, which are queries that obtain data from tables and return a resultset. The following is the complex SELECT command’s general, if highly simplified, format: SELECT select_list [INTO new_table_] FROM table_source [WHERE search_condition] [GROUP BY group_by_expression] [HAVING search_condition] [ORDER BY order_expression [ASC │ DESC] ] The following simple query returns all movies in the table tblFilms. The asterisk serves as the variable for all columns in the table. SELECT * FROM tblFilms Specify the column names to select specific columns, as shown here: SELECT FilmNr, Filmtitle FROM tblFilms To avoid unnecessary server and network load, select only those columns that you actually need. If you use column names that contain spaces or special characters, you must enclose the names in angle brackets, as shown here, or apostrophes: SELECT [Field name with spaces] FROM Table The following is a better example that conforms to the ANSI SQL standard: SELECT "Field name with spaces" FROM Table Identity Column Output You can use the default column name IDENTITYCOL to output the column that you defined as the table’s identity column. For example, this command SELECT IDENTITYCOL, Filmtitle FROM tblFilms returns the FilmNr and the Filmtitle columns. The FilmNr column is defined as the identity column for file://C:\Documents%20and%20Settings\richard.welke.ECI\Local%20Settings\Temp\~hh8... 3/21/2004 Transact-SQL Page 3 of 53 the table tblFilms. Use of Quotation Marks The ANSI SQL standard allows only double quotation marks to identify database object names, whereas character strings are enclosed in single quotation marks. In Access mdb databases, angle brackets are used to enclose database object names, and double quotation marks are used to identify character strings. If you copy queries from Access mdb databases, you must at least substitute single quotation marks for the double quotation marks that enclose character strings. If the character string already contains single quotation marks, you must replace them with two single quotation marks. For example, “Big Momma’s House” would become ‘Big Momma’’s House.’ In SQL Server/MSDE, you can also use angle brackets for object names. However, if you adhere to the ANSI SQL programming standard, you should use double quotation marks, and make sure that the QUOTED_IDENTIFIER database option is ON. If the QUOTED_IDENTIFIER database option is OFF, you have to use angle brackets to delimit identifiers, and you may use double quotes to delimit character strings. Aliases with AS In the Access results display, the column names are used as the column headings. You can edit the column names with the AS command to specify new names, as shown here: SELECT FilmNr AS Filmnumber, Filmtitle AS 'Film Title' FROM tblFilms If the new column names contain spaces or special characters, be sure to enclose the column names in single quotation marks. For aliases, you can also use the abbreviated version, as displayed here SELECT FilmNr Filmnumber, Filmtitle 'Film Title' FROM tblFilms without the AS command. You can also place an alias in front, like this: SELECT Filmnumber = FilmNr, 'Film Title' = Filmtitle FROM tblFilms You can use aliases for table names as well, such as, for example: SELECT f.FilmNr, f.Filmtitle FROM tblFilms AS f Tables from Other Users, Databases, or Servers SQL Server/MSDE allows a user to create his or her own tables, provided that the user has the required permissions. This makes it possible for multiple users to choose the same table name. In those cases, SQL Server/MSDE differentiates between the tables by adding the user name as a prefix. By default, users can see only their own tables and those tables by the user dbo. With the appropriate permissions, a user can also access others’ tables, even those in other databases located on the same or different servers. The general syntax is as follows: file://C:\Documents%20and%20Settings\richard.welke.ECI\Local%20Settings\Temp\~hh8... 3/21/2004 Transact-SQL Page 4 of 53 SELECT * FROM server.database.user.table Figure 9-1 illustrates the definition of a view that displays the name and dbname fields for the syslogins table from the master database. Figure 9-1 Access to the master database SQL Server/MSDE lets you use tables and views from other servers. These other servers may be SQL Server/MSDE systems or systems that run other database products, such as Oracle or Microsoft Access. The servers must be accessible through the object linking and embedding database (OLE DB) provider or open database connectivity (ODBC) driver. Setting up access to another database server requires definition of a linked server or of linked tables through data sources. See Chapter 24, “External Data Sources,” for more information on setting up linked servers. The view shown in Figure 9-2 accesses the server PN-Notebook, where it reads the tblFilms table in the ContosoSQL database. PN-Notebook was set up as a linked server. file://C:\Documents%20and%20Settings\richard.welke.ECI\Local%20Settings\Temp\~hh8... 3/21/2004 Transact-SQL Page 5 of 53 Figure 9-2 Access to a linked server PN-Notebook Special Cases The programming of stored procedures (see Chapter 8, “Stored Procedures”) often involves special cases of the SELECT command. For example, the commands SELECT 'Text' or SELECT 12+34/3 return a resultset based on a text column or a calculated value. If a query results in exactly one value, you can assign this value to a variable, such as SELECT @Variable = Value or SELECT @Variable = Fieldname FROM Table. SQL Server/MSDE allows the syntax SELECT 'Text' or SELECT NumericalExpression. With Access mdb queries, however, you must always specify a FROM table as well, even if 'Text' or NumericalExpression are not relevant to the table. Calculated Columns Columns based on SELECT commands can also be calculated, which means they can be derived from other columns. The following query, for example, returns every film’s length, plus 45 minutes: SELECT Filmtitle, Length + 45 FROM tblFilms If you do not use AS to specify a column name for a calculated field, SQL Server/MSDE uses the name Expr<n>, with n denoting the column number.
Recommended publications
  • Docstar SQL Edition
    DocSTAR SQL Edition Technical Documentation Chapter 1 Requirements ..................... 1-3 Requirements ...................................................1-4 Hardware ........................................................ 1-4 Software .......................................................... 1-4 Chapter 2 Setup.................................. 2-1 General Setup Guidelines .............................2-2 Installation Scenarios ................................... 2-2 Summary of Steps......................................... 2-3 Installation Steps for Scenarios .................. 2-5 DocSTAR Setup Routine ............................ 2-6 Log files.......................................................... 2-7 Individual Setup Steps ...................................2-9 Prepare Existing DocSTAR Host............... 2-9 Setup NT Server............................................ 2-9 Setup SQL Server ....................................... 2-10 Copy existing DocSTAR 2.3 data to new NT server 2-12 Configure SQL Database Structures........ 2-12 Install ODBC Drivers................................. 2-12 Install DocSTAR SE.................................. 2-13 Database Activity (Initialize, Update, or Upsize) 2-19 Restore DocSTAR SE Data on a Bare NT Server 2-25 Final DocSTAR Steps................................ 2-25 Copy Setup Routines to Host.................... 2-26 Manual Processes......................................... 2-29 Manually Configure SQL Database Structures 2-29 Manually Edit Data Source Names.......... 2-34 Convert Jet
    [Show full text]
  • Windows Multi-DBMS Programming
    • Windows Multi-DBMS Programming Using C++, Visual Basic®, ODBC, OLE2, and Tools for DBMS Projects Ken North John Wiley & Sons, Inc. New York • Chichester • Brisbane • Toronto • Singapore : . ... • - . Contents Preface XXV Chapter 1 Overview and Introduction 1 The Changing Face of Development 2 Overview 2 Required Hardware and Software 3 Chapter 2 Windows Software Development: Concepts and Issues Terms and Concepts 5 Windows Features and Database Applications 7 Processes, Tasks, and Threads 7 Multitasking 8 Protected Addresses and Safe Multitasking 8 Threads: NetWare and Win32 9 Scheduling 9 Windows Programming 10 Static and Dynamic Linking 11 Dynamic Link Libraries 12 INI Files 12 Resources and Help Files 12 Dialog Boxes 13 Custom Controls 14 Notation 14 Windows Developer's Notebook 15 Baselines 15 Version Control 16 Common Development Steps 16 VH viii Contents Pseudocode 17 Debugging 17 Visual Programming 19 Formal Development Methods 19 Crafting Code for Windows 20 GUI Design Considerations and Database Applications 20 Chapter 3 Database Applications: Concepts and Issues 22 Building Database Applications 22 Database Architectures 23 DBMS Evolution 23 ISAM 24 Network and Hierarchical Databases 24 SQL and Relational Databases 25 Desktop, File Server, and Client-Server 29 Terms and Concepts 30 SQL Concepts 38 Database Design 39 Network Database Design 40 Relational Database Design 40 Query Optimization 45 Issues 48 Sample Database and Applications 49 Info Enterprises 49 Sample Applications 50 Road Map for Database Developers 55 Tools
    [Show full text]
  • Developing Multiuser and Enterprise Applications
    26_0672329328_ch22.qxd 5/3/07 3:28 PM Page 909 CHAPTER 22 IN THIS CHAPTER . Why This Chapter Is Important Developing Multiuser . Designing Your Application with Multiuser Issues in Mind and Enterprise . Understanding Access’s Applications Locking Mechanisms . Understanding the Client/Server Model . Deciding Whether to Use the Client/Server Model Why This Chapter Is Important . Understanding the Roles That Many people forge right into the application development Access Plays in the Application process with little worry about the scalability of the appli- Design Model cation. Even a simple application that begins as a single- . Learning the Client/Server user application can develop into a multiuser or Buzzwords enterprise-wide application. Unfortunately, the techniques . Upsizing: What to Worry About you can get away with in the single-user application can wreak havoc in a network or client/server environment. It . Proactively Preparing for is therefore necessary to think about the future when you Upsizing design any application. Although the initial development . Using Transaction Processing process might be more complex, if written properly, the . application will survive any growth that it experiences. Practical Examples: Getting Your Application Ready for an This chapter focuses on writing applications that transition Enterprise Environment easily from the single-user environment through the enter- prise client/server environment. Designing Your Application with Multiuser Issues in Mind When you develop applications that multiple users will access over the network, you must make sure they effec- tively handle sharing data and other application objects. Many options are available for developers when they design multiuser applications, and this chapter covers the pros and cons of these options.
    [Show full text]
  • Information Technology Module for Managers Database Design
    Information Technology Module for Managers Database Design Lesson No. 2 In this lesson you will come to know the history of database files and about Relational Database Management System (RDBMS). You will also come to know briefly about Client/Server computing. History of Files: From the inception of computing we know three types of files. They are: Sequential Model Navigational Model Relational Model We are now seeing the emergence of the fourth type: Object Model (along with relational/object hybrids) Along with the above evolution, there has been a shift of responsibility from the application to the database. For example: in sequential model, application was responsible for locating a record and enforcement of business rules. 1.1 Sequential Model Sequential files consist of fixed length records with fixed length fields. The old 80-column cards are example of this. A variation of this came later, when a character was used as a delimiter, instead of depending on the end of a record in fixed location. Visual Basic supports both these forms of sequential files. VB uses Open, Close and other variety of statements. An advantage of this sequential model is its simplicity. On the other hand the disadvantage is that search always begins from the first records and one after the other. Some improvements were introduced later whereby Random search became possible. 1.2 Navigational Model Also called Hierarchical Model. It was a major improvement. The detail of navigation is kept hidden from the developer so that the database did the dirty work of locating a record. Common examples were dBase and Btrieve files.
    [Show full text]
  • Developing a Web Enabled Database System: an Academic Project
    Session 1658 Developing a Web-Enabled Database System: An Academic Project Paul I-Hai Lin - Indiana University-Purdue University Fort Wayne Melissa Lin - University of Florida Aik Mon - GE Industrial Systems ABSTRACT Database and Web integration offers a cost effective way to provide value added access to data stored at multiple locations through a Web browser. This paper discusses two methodologies for implementing a remote database query systems using Web browsers. I. Introduction In May 2000, we developed a Web-enabled alumni database for remote access by our faculty and staff. The alumni database was created from a spread sheet that contains the following fields: Title, Last Name, First Name, Middle Initial, Degree Received, Major, Graduation Date, Address, City, State, Zip code, Email address, Phone, Employer, ID, Last Gift Amount, Last Gift date, and Total Gift Amount. The developed Web-based alumni database has the following capabilities: • View data records for all alumni (20 records per screen) • Find a specific alumnus or group of alumni by their Last Name, First Name, Graduation Date, City, State, or Employer • Update specific fields on alumni data records • Update, delete, and add alumni records to database Although the data warehouse and Web-enabled databases are well known and matured in commercial sector, for us, this is a new challenging and requires additional research. This paper is not intended to provide a comprehensive study report of tools and architectures for building database and Web integration systems. However, the Internet protocols, languages and tools, databases, Web servers, CGI, and server-side scripting are highlighted in various sections to help the selections of programming tools, system platform, Web servers, and databases for this Web- enabled alumni database system.
    [Show full text]
  • Access Upsizing Project, It Is Important to Understand That There Are a Variety of Upsizing Methodologies
    Strategic Initiatives: Evolving Microsoft Access Applications to Microsoft SQL Server Learn When and How to Upsize to SQL Server Prepared by: Dan Haught Executive Vice President FMS Professional Solutions Group www.fmsinc.com/consulting Toll Free (866) 367-7801 Local (703) 356-4700 Strategic IT Initiatives: Evolving Microsoft Access Applications to Microsoft SQL Server Learn When and How to Upsize to SQL Server Dan Haught, Executive Vice President of FMS, is globally recognized as a software development expert and brings extensive experience building database applications using state-of-the-art technology and program management to complex client engagements. Dan has a UNIX/C programming background, and is an expert in Access, VB, SQL, .NET and web development. He is the primary developer of several FMS products, a frequent speaker at industry conferences, and a contributing editor to several monthly magazines including Advisor Access/VB/SQL and ASP.NET PRO. Dan has co-authored several books on software development, including the Microsoft Jet Database Engine Programmer's Guide (Microsoft Press). He is responsible for new product origination, ensures that all FMS products and solutions employ standards-based best practices, and manages the daily operations of the development teams. Dan joined FMS in 1992. Executive Summary This whitepaper explores the issues related to upsizing Microsoft Access applications to take advantage of the performance, security, and reliability of Microsoft SQL Server. Topics discussed include: The Value of Access in Your Organization – a brief discussion of how Access provides power and agility to an organization’s users Making the Decision: When to Upsize – an evaluation of the criteria to decide if an application has outgrown the capabilities of access Microsoft Access Data Architectures – a discussion of the type of data architectures that Access supports Types of Upsizing Projects – There are several approaches to upsizing.
    [Show full text]
  • Software Development with Visual Basic
    B.Com. (C.A.) Third Year Core Paper No. 14 SOFTWARE DEVELOPMENT WITH VISUAL BASIC BHARATHIAR UNIVERSITY SCHOOL OF DISTANCE EDUCATION COIMBATORE – 641 046 1 (Syllabus) B.Com. (Computer Applications) – III Year Core Paper-14 SOFTWARE DEVELOPMENT AND VISUAL BASIC Objectives : To enable the students to develop a front end tool for Customer Interaction in Business. UNIT – I Introduction – Client/Server – Benefits of Client/Server – Downsizing – Upsizing- Right sizing – Client/Server Models – Distributed Presentation – Remote Presentation – Remote Data – Distributed Logic – Distributed Data – Client/Server Architecture – Technical Architecture – Application Architecture – Two Tier Architecture – Three Tier Architecture OLTP & n Tier Architecture. UNIT – II Introduction to Visual Basic – Steps in VB Application – Integrated Development Environment (IDE) – Menu Bar – Tool Bar – Project Explorer Window – Property Window – Toolbox – Properties, Methods and Events – Event Driven Programming – Working with Forms – Variables – Scope of Variables – Constants – Data Types. UNIT – III Functions – Procedures – Control Structure : If – Switch – Select – For – While – Do While – Arrays – User Defined Data Types – Data Type Conversions – Operators – String Functions – Data and Time Functions. UNIT – IV Creating and Using Standard Controls : Form, Label, Text box, Command Button, Check Box, Option Button, List Box, Combo Box, Picture Box, Image Controls, Scroll Bar – Drive List Box – Directory List Box – Time Control, Frame, Shape and Line Controls – Control Arrays – Dialog Boxes – Single Document Interface (SDI) – Multiple Document Interface (MDI) – Menu – Menu Editor – Menu Creation. UNIT – V Data Controls – Data Access Objects (DAO) – Accessing and Manipulating Database – Recordset – Type of Recordset – Creating a Recordset – Modifying, Deleting Records – Finding Records – Data Report – Data Environment – Report – Designer – Connection Object – Command Object – Section of the Data Report Designer – Data Report Controls.
    [Show full text]
  • Anlegen Von Datenbanken Im Microsoft SQL Server 2014 Modellbasiertes Forward Engineering Und Migration Von Access-Datenbanken
    Anlegen von Datenbanken im Microsoft SQL Server 2014 Modellbasiertes Forward Engineering und Migration von Access-Datenbanken Manfred Sommer Stand: Februar 2016 Manfred Sommer: Anlegen von Datenbanken im Microsoft SQL Server 2014 1 Inhaltsverzeichnis 1 Einleitung ................................................................................................................... 2 2 Anlegen einer neuen SQL Server Datenbank ......................................................... 2 2.1 Anlegen mit einem Datenmodellierungswerkzeug ...................................................... 3 2.1.1 Logisches und physikalisches ERwin-Modell erzeugen ....................................................... 4 2.1.2 Ziel-Server wählen ................................................................................................................ 5 2.1.3 Ziel-Datenbank mit dem SQL Server Management Studio anlegen ..................................... 6 2.1.4 Mit der SQL Server-Datenbank verbinden ............................................................................ 6 2.1.5 Tabellen mit Forward Engineering anlegen .......................................................................... 8 2.1.6 Synchronisation mit Complete Compare ............................................................................. 10 2.2 Anlegen mit einem SQL-DDL-Skript ........................................................................... 12 2.3 Datenbankdiagramm erzeugen ................................................................................... 15 2.4
    [Show full text]
  • Copyrighted Material
    19_046845 bindex.qxp 3/21/07 9:48 PM Page 527 Index Index Access Projects A based on SQL Server databases, 260, 262–263 ACCDB file format, 2, 29 creating, 259–263 ACCDB files, 253, 278, 281 described, 253 ACCDE file format, 2 displaying new, 278, 284 ACCDE files, 331 as a front end to SQL Server, 253–254 Access 2007 migrating existing Access databases to, 277–284 changes from Access 2003, 2 reusing code across multiple, 308 as a front end to other databases, 132 storage locations for objects seen from, 254 three-tiered applications and, 15 working with SQL Server objects, 264–277 Access 2007 VBA Access runtime, 330 changes from Access 2003, 2–3 Access tables programming concepts, 3–25 checking dates in, 277 uses of, 1 exporting contents to a spreadsheet, 205, 206 Access database files. See ACCDB files ActionSuccess event, 116, 120–121 Access databases Activate event, 247 attaching SharePoint lists to, 231 active plans, retrieving, 472 changes to existing prior to migration, 277 ActiveConnection property, 143, 147, 151, 155 connecting to, 132 ActiveX controls, 305–308 importing a SQL Server database, 203–204 ActiveX Data Objects. See ADO importing data from, 201 Activity Diagrams, 7–8, 9, 10 separating into two database files, 319–322 actor in a Use Case Diagram, 5 upsizing, 277–284 Add Comment button, 337 Access designer, 271 COPYRIGHTEDAdd MATERIAL Current Contact To Project button, 339, 340 Access field data types. See field data types Add method, 112, 113 Access forms, generating prototype screens, add mode, 442–443, 449–450 336–340 Add mode flag, 169, 176 Access macros, VBA instead of or with, 1 Add New navigation button, 137 Access Options, Advanced, 316–317 Add Table dialog box, 275 Access Project file, 278, 281 Add Watch dialog box, 69, 71 19_046845 bindex.qxp 3/21/07 9:48 PM Page 528 AddEmptyProjectRecord procedure AddEmptyProjectRecord procedure, 419, 433 ADP file, opening, 278 Add-in Manager, 313 ADPs.
    [Show full text]
  • Client-Server-Computing.Pdf
    This page intentionally left blank Copyright © 2009, New Age International (P) Ltd., Publishers Published by New Age International (P) Ltd., Publishers All rights reserved. No part of this ebook may be reproduced in any form, by photostat, microfilm, xerography, or any other means, or incorporated into any information retrieval system, electronic or mechanical, without the written permission of the publisher. All inquiries should be emailed to [email protected] ISBN (13) : 978-81-224-2861-2 PUBLISHING FOR ONE WORLD NEW AGE INTERNATIONAL (P) LIMITED, PUBLISHERS 4835/24, Ansari Road, Daryaganj, New Delhi - 110002 Visit us at www.newagepublishers.com Preface In recent years there have been significant advances in the development of high performance personal computer and networks. There is now an identifiable trend in industry toward downsizing that is replacing expensive mainframe computers with more cost-effective networks of personal computer that achieve the same or even better results. This trend has given rise to the architecture of the Client/Server Computing. The term Client/Server was first used in the 1980s in reference to personal computers on a network. The actual Client/Server model started gaining acceptance in the late 1980s. The term Client/Server is used to describe a computing model for the development of computerized systems. This model is based on the distribution of functions between two types of independent and autonomous entities: Server and Client. A Client is any process that request specific services from server processes. A Server is process that provides requested services for Clients. Or in other words, we can say “A client is defined as a requester of services and a server is defined as the provider of services.” A single machine can be both a client and a server depending on the software configuration.
    [Show full text]
  • Recordset for Reporting the Standings
    Structure of Sailors.mdb Introduction and Objective Sailors. mdb supports a hypothetical web site for competitive sailors. The web site includes pages to notify sailors of upcoming regattas, changes in rules, reports on past regattas, and personalized pages based on each sailor's interests. Additional features allow the posting and statistical analysis of regatta results and the ranking of sailors. Vocabulary and Business Rules Sailors, in this database are people who race sailboats. These people have the normal personal information such as names and nationalities, as well as an assigned professional class, which reflects their commitment and accomplishment in the sport of yachting. The most skilled sailors, those of Olympic caliber, are rated Professional Class 1 while those who compete at an amateur level are class 3. Boats are owned by Sailors. A boat has a name and an identifying sail number. Every boat is of a boat class. A Boat Class is a group of boats of the same shape, sail area and hull size, thus ensuring an even competition among the sailors. Sailors generally race in one class only and thus are not interested in information for boats of other classes. Sailors race under the aegis of yacht clubs, the organizations which typically sponsor regattas. Yacht clubs have an identifying flag called a club burgee, may have a web site, and each year a yacht club has a meeting at which time information for the season is disseminated. Larger boats are limited to sailing from clubs with a crane to hoist the boat from its trailer to the water.
    [Show full text]
  • More SOL- Salutions to Common Problems
    APPENDIX A More SOL- Salutions to Common Problems Problem 1: Begin a Label Report at Any Label on the Sheet MosT LABEL RuNs leave unused labels an the last sheet. The following technique will start a label run at a specific label position, so you can use those partially used sheets. The components are a form, a temporary table, and a label report. You'll use the form to identify the position of the first available label. Then, an event procedure will populate the temporary table with blank rows, with one blank row for each missing label. The number of blank rows is determined by the value you enter. Ifyou enter a value of 3 (meaning that the first label is in the third label position), the procedure will add two blank rows. Next, the procedure appends the label data below the blank rows. The report doesn't care that the rows are empty; the positions are still filled in the label report. Each blank row represents a blank label, pushing the actual data down to the first label. This technique doesn't accommodate missing labels between the first and last label. Example: tblOne, frmOne, and rptOne Solution 1: SELECT, DELETE, and INSERT INTO Ta create the temporary table: 1. In the Database window, select the table that contains the data you're printing. 2. Press Ctr1 +C to copy the table to the clipboard. 3. Press Ctrl+V topaste a copy ofthe table. In the Paste Table As dialag box, enter a name for the dummy table. (We'll be working with tblOne.) Select the Structure Only option button in the Paste Options section, and dick onOK.
    [Show full text]