Implementation of a batch file to create and populate a database
You are required to demonstrate advanced knowledge of Views, Stored Procedures, and Batches as follows:
You must write a batch file which creates and populates a database of between 4 and 6 tables. The database must be of your own making and should be of an area of interest to you or related to your work. The database must be stored in a folder which is named after yourself. As well as creating tables, the batch file must cater for keys.
The number of records to be inserted can be decided by yourself but should be enough only to warrant successful demonstration and execution of your queries. Careful consideration, therefore, should be given to the type and amount of data you wish to store.
You are then required to have a separate SQL file which demonstrates the use of Views and Stored Procedures. No more than 8 queries should be used to demonstrate Views and no more than 12 queries should be used to demonstrate Stored Procedures – enough to demonstrate advanced knowledge of both.
Marks are allocated as follows:
- Implementation of a batch file to create and populate a database: 25%
- Creation and use of Views: 25%
- Creation and use of Stored Procedures: 50%
The code inside both views and stored procedures must be complex and include joins, subqueries, aggregate functions etc.
Furthermore, specifically relating to Stored Procedures you must demonstrate advanced use of parameters, insert operations, error handling and the use of return.
Basic documentation should be provided with the batch file, detailed documentation with everything else (outlining what the code does, why you believe it to be advanced, issues you encountered and overcame/did not overcome, links to websites/articles you found useful etc.). The provision of business cases is not a requirement for this assignment.