Index of /~raj/elna-lab-2010/ch4/company

[ICO]NameLast modifiedSizeDescription

[PARENTDIR]Parent Directory   -  
[   ]load-project.sql 2018-05-17 10:23 102  
[   ]load-worksOn.sql 2018-05-17 10:23 102  
[   ]load-employee.sql 2018-05-17 10:23 104  
[   ]load-department.sql 2018-05-17 10:23 106  
[   ]load-dependent.sql 2018-05-17 10:23 106  
[   ]load-dloc.sql 2018-05-17 10:23 106  
[   ]dloc.dat 2018-05-17 10:23 192  
[   ]dept_locations.sql 2018-05-17 10:23 200  
[   ]department.sql 2018-05-17 10:23 210  
[   ]worksOn.sql 2018-05-17 10:23 231  
[   ]department.dat 2018-05-17 10:23 247  
[   ]project.sql 2018-05-17 10:23 261  
[   ]dependent.sql 2018-05-17 10:23 264  
[   ]source.sql 2018-05-17 10:23 274  
[   ]project.dat 2018-05-17 10:23 385  
[   ]employee.sql 2018-05-17 10:23 408  
[   ]dependent.dat 2018-05-17 10:23 504  
[   ]worksOn.dat 2018-05-17 10:23 1.1K 
[   ]employee.dat 2018-05-17 10:23 4.0K 
[   ]company.tar 2018-05-17 10:23 30K 

There are three files for each table in this directory. For example for the DEPARTMENT table the three files are:
  1. department.sql: contains the SQL Create Table statement to create the table.
  2. department.dat: contains data for the table to be loaded using the MySQL load command.
  3. load-department.sql: contains the LOAD command to load data into the table.

The file, source.sql, contains MySQL "source" commands to execute the "create table" and "load" commands for each table.

After signing in to MySQL and changing to "company" database, simply run the following command to create and populate the tables:

mysql> source source.sql