Home

SQL Startup

 

Introduction to SQL

 

Overview

The Structured Query Language (SQL) is the most popular language used in computers to create and manage databases. SQL is a language with its own syntax and grammar. SQL is a universal language that doesn't belong to a particular company. This makes it easy for different companies or programming environments to adopt it. In this site, we will study techniques of creating databases and we will use the SQL.

 
SQL can be pronounced Sequel or S. Q. L. On this site, we will consider the Sequel pronunciation. For this reason, the abbreviation will always be considered as a word, which would result in “A SQL statement” instead of “An SQL statement". Also, on this site, we will regularly write, “The SQL” instead of “The SQL language, as the L already represents Language.
 

Learning SQL

SQL is a standard language and universally used. Like most other computer languages such as C, C++, Pascal, C#, or Java, you need a way to use it on your computer. This access is provided by a language engine that can receive your instructions and produce a result. In other words, you need a program that uses SQL as its means of communication. There are many of them in the market. They include Corel Paradox, Oracle, Microsoft Access, MySQL, Microsoft SQL Server, Sybase, etc. Some of these programs are easier to get, some are not.

Although the SQL is monitored by an independent organization, it is not unusual that each company adds a few features to its own implementation. For this tutorial, we will try to use the most standard implementation possible. Since we cover Microsoft Access and Microsoft SQL Server separately in http://www.functionx.com, for our lessons, we will mostly use MySQL.

MySQL is a database application whose popularity has been growing tremendously. If it is getting so commonly used, it is an indication that it is good, efficient, effective, stable, and reliable.

 

The Microsoft SQL Server Desktop Engine

 

Introduction

If you don't want to use MySQL, you can use an alternative from Microsoft. This is provided through the Microsoft SQL Server Desktop Engine or MSDE. Like MySQL, MSDE has its own advantages:

  • MSDE is freely available
  • The interpreter used by MSDE is highly compatible with the SQL standard and, coincidentally, is the same used by Microsoft SQL Server
 

MSDE Setup

To get Microsoft SQL Server, you can first download it. To download the trial version of Microsoft SQL Server, go to the Microsoft web site at http://www.microsoft.com and do a search on "Trial Software". You should be given a link to the Microsoft SQL Server trial edition. The advantage of Microsoft SQL Server over MSDE is that the former provides a visual environment that allows you to see what you are doing. MSDE doesn't have an interface: it relies on external products, such as Microsoft Access or Microsoft SQL Server, to show its result. After downloading Microsoft SQL Server, follow the instructions to install it.

Most SQL expressions used in these lessons can be run in most database environments. To reduce the number of instructions given in the lessons, for the rest of this site, we will give instructions for the MySQL.

 

Practical Learning Practical Learning: Setting Up Microsoft SQL Server

If you will be using another database environment to learn SQL, you can skip this exercise. This is only meant to help you set up MSDE

  1. First download the MSDE from the Microsoft web site. To get it, go to http://www.microsoft.com and do a search on MSDE. A link will let you know how to download it
     
  2. After downloading MSDE, click Close
  3. To install Microsoft SQL Server 2000 Desktop Engine, open the Command Prompt and switch to the folder that contains the package you downloaded. By default, this would be C:\MSDERelA
     
  4. In your mind, make up a password you will use for this account. As for me, I will use Yevol1
    Therefore, type setup SAPWD="Yevol1"
    In the double-quotes, provide a password of your choice
     
  5. Press Enter
    When the installation is over, you may be asked to restart the computer
     
  6. If so, click Yes
  7. After restarting the computer, to start the server, in the system tray, right-click the icon with a red dot
     
  8. In the context menu, click MSSQLServer - Start
  9. To make sure that it restarts every time the computer comes up, double-click that same icon
  10. On the dialog box, click the Auto-Start Service When OS Starts check box
     
  11. Then close the dialog box

Environment Startup

Once you get your database environment ready, you should test it. Before testing it, you must start or launch it. Each environment provides its own approach.

If you plan to use Microsoft Access, we have a separate site for it. In the same way, if you will be using Microsoft SQL Server, we created its own site.

If you will be using MySQL, you can start it as follows:

 

Practical Learning Practical Learning: Starting MSDE

  1. To start MSDE, open a DOS command prompt
  2. At the command prompt, type osql -E and press Enter
  3. To exit from the MSDE prompt, type exit and press Enter
  4. To close the prompt, type exit and press Enter
 

Copyright © 2004-2007 FunctionX, Inc. Next