6IBM Informix OnLine Database Server Administrator’s Guide
Demonstration Database
You can run thedbaccessdemo5 script again whenever you want a fresh
demonstration database to work with. The script prompts you when the
creation of the database is complete and asks if you would like to copy the
samplecommand files to the current directory. Answer “N” to the prompt if
you have made changes to the sample files and do not want them replaced
with the original versions. Answer “Y” to the prompt if you want to copy
over the sample command files.
To create and populate thedemonstration database in the IBMInformix OnLine
environment
1. Setthe INFORMIXDIR environment so that it contains the name of the
directory in which yourIBM Informix products are installed.
SetSQLEXEC to $INFORMIXDIR/lib/sqlturbo. (For a full description
of environment variables, seeIBM Informix Guide to SQL: Reference.)
2. Create a new directory for theSQL command files.
Create the directory by entering:
mkdir dirname
3. Make the new directory the current directory by entering:
cd dirname
4. Create the demonstration database and copy over the sample
command files by entering:
dbaccessdemo5 dbname
The data for the database is put into the root dbspace.
To give someone else theSQL privileges to access the data, use the GRANT
andREVOKE statements. The GRANT and REVOKE statements are described
inIBM Informix Guide to SQL: Reference.
Touse the command files that have been copied to your directory, you must
haveUNIX read and execute permissions for each directory in the pathname
of the directory from which you ran thedbaccessdemo5 script. To give
someoneelse the permissions to access the command files in your directory,
use the UNIXchmod command.