Unformatted text preview:

SQL HW1Using MySQLOPTIONAL: Connecting to the MySQL Server from OpenOffice Base on WindowsSome basic SQL statements:Formulate the following queries in SQL and turn in a hardcopy of each query:SQL HW1Turn in as a hardcopy at the start of next class period. You may work this assignment in groups.Using MySQLThe MySQL server is on candler.cs.unca.edussh to candler before connecting to the MySQL serverLogon to the server using the student account as follows:candler> mysql –u studentThis account does not have a passwordUse the orderEntry database for this HW: mysql> use orderEntry;To run a query that has been stored in a file with the name query1.sql (in the current working directory):mysql> source query1.sql;OPTIONAL: Connecting to the MySQL Server from OpenOffice Base on Windows Download the ‘Driver Installer (zipped EXE)’ for Windows from:http://dev.mysql.com/downloads/connector/odbc/3.51.htmlFollow the ‘Configuring a MyODBC DSN on Windows’ instructions on:http://dev.mysql.com/doc/refman/5.0/en/myodbc-configuration-dsn-windows.htmlIn Base select connect to an ‘existing database’ and follow instructions.Some basic SQL statements: Show the databases that are available for you to query:mysql> show databases;Select a database with the use command:mysql> use <dataBaseName>;Show the tables in a database:mysql> show tables;After executing the use <dataBaseName> commandView the attributes of a table:mysql> describe <tableName>;After executing the use <dataBaseName> commandFormulate the following queries in SQL and turn in a hardcopy of each query:Develop queries to answer the following questions from page 125 of your textbook:2, 5, 6,


View Full Document

UNCA CSCI 343 - SQL notes

Download SQL notes
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view SQL notes and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view SQL notes 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?