VISUAL QUICKSTART GUIDE SQL Second Edition [Electronic resources]

Chris Fehily

نسخه متنی -صفحه : 169/ 8
نمايش فراداده

l xmlns="http://www.w3.org/1999/l">

  • What You'll Need

    To replicate this book's examples on your own computer, you'll need:

    • A text editor

    • The sample database

    • A database management system

    A text editor . Typing short or ad-hoc interactive SQL statements at a prompt is convenient, but you'll want to store nontrivial SQL programs in text files. A

    text editor is a program that you use to open, create, and edit

    text files, which contain only printable letters, numbers, and symbolsno fonts, formatting, invisible codes, colors, graphics, or any of the clutter usually associated with a word processor. Every operating system includes a free text editor. Windows has Notepad, Unix has vi and emacs, and Mac OS X has TextEdit, for example. By convention, SQL files have the filename extension

    .sql , but you can use

    .txt (or any extension) if you prefer.

    Tips

    • Windows users might want to forgo Notepad for a better alternative such as TextPad ($31 U.S.; www.textpad.com).

    • You

      can type SQL programs in a word processor such as Microsoft Word and save them as text-only files, but that practice causes maintenance problems (and professionals consider it to be bad form).

    The sample database . Most examples in this book use the same database, described in "The Sample Database" in Chapter 2. To build the sample database, follow the instructions in Appendix A. If you're working with a production server DBMS, you might need permission from your database administrator to run SQL programs that create and update data and database objects.

    A database management system . How do you get SQL? You don'tyou get a DBMS that understands SQL and feed it an SQL program. The DBMS runs your program and displays the results, as described in the next chapter.