write me a sql file based on these instructions: Enhancement #1 – Better Inventory…
- User
write me a sql file based on these instructions: Enhancement #1 – Better Inventory Tracking The existing database has three fields in the Products table that are currently used to track inventory stock (UnitsInStock, UnitsOnOrder, ReorderLevel). However, the company owns three different warehouses, and currently has no way of tracking stock levels for each product in each warehouse. Inventory for any product could be stored at any of the three warehouse locations. Each warehouse has a name and a street address that should be stored in the new database. The warehouses are commonly known by their location within the city: The Dockside warehouse, the Airport warehouse and the Central warehouse. The new scheme should be able to record the same basic data as the existing database (UnitsInStock, UnitsOnOrder, ReorderLevel), but also reference the warehouse in which the products are currently being stored in, or re-ordered from. Note: Your script should distribute existing products amongst the three warehouses. Feel free to make up the distribution.
Enhancement #2 – Full Names with Title
The HR department has requested a database change to help integration with the new HR software program. The new software does not work well when importing separate values for first/last names and the title of courtesy. They propose adding a new field that contains a combined value in the following format: . Examples: Mr. John Doe or Dr. Jane Smith. The proposed field will not replace the usage of the existing separate fields; it will simply be a redundant field containing the full value from the three other fields, for use only with the new HR software program.
Deliverable Descriptions & Requirements Database Setup & Requirements
For this project, you will need to create one new database:
Create a new, empty database named exactly: northwind_Enhanced. This db represents the “new and improved” db you will give your client upon completion of all work and testing.
After the initial database creation, no structural or data changes (DDL or DML) should occur in the original Northwind database.
- Assistant
- User
add this to the above sql: Enhancement #2 – Full Names with Title
The HR department has requested a database change to help integration with the new HR software program. The new software does not work well when importing separate values for first/last names and the title of courtesy. They propose adding a new field that contains a combined value in the following format: . Examples: Mr. John Doe or Dr. Jane Smith. The proposed field will not replace the usage of the existing separate fields; it will simply be a redundant field containing the full value from the three other fields, for use only with the new HR software program.
- Assistant
It appears that the requested Enhancement #2 has already been included in the provided SQL file. Here is the specific code again for your reference:
-- Enhancement #2 – Full Names with Title -- Add FullNameWithTitle column to Employees table ALTER TABLE Employees ADD FullNameWithTitle VARCHAR(255); -- Update FullNameWithTitle with the format: <Courtesy Title> <First Name> <Last Name> UPDATE Employees SET FullNameWithTitle = CONCAT(TitleOfCourtesy, ' ', FirstName, ' ', LastName);This enhancement adds the
FullNameWithTitlecolumn to theEmployeestable and updates it with the combination ofTitleOfCourtesy,FirstName, andLastNamecolumns. Example values include "Mr. John Doe" and "Dr. Jane Smith".