Presentation is loading. Please wait.

Presentation is loading. Please wait.

By Justin LeBourdais. Description Designed for my mother’s business Small updateable database for her clients and employees Designed for ease of use,

Similar presentations


Presentation on theme: "By Justin LeBourdais. Description Designed for my mother’s business Small updateable database for her clients and employees Designed for ease of use,"— Presentation transcript:

1 By Justin LeBourdais

2 Description Designed for my mother’s business Small updateable database for her clients and employees Designed for ease of use, most code that needs to be run would already created.

3 Outcomes Database that works Easy to use, database doesn’t seem overly complex All SQL to create and to update is available in txt files

4 Problems Data model and database has a few incorrect relationships Didn’t follow naming convention correctly, used own method.

5 Lessons Learned Follow conventions! Data models are important. If it is wrong, you will have trouble later on Keep notes and all SQL code that you use. It will save you lots of work later.

6 Incorrect Model

7 Better Model

8 Example Code USE capstone; SELECT CAST(a.FirstName + ' ' + a.LastName AS CHAR(20)) "Employee Name", CAST(ahw.Week AS SMALLDATETIME) "Work Week", CAST(ahw.sunday + ahw.monday + ahw.tuesday + ahw.wednesday + ahw.thursday + ahw.friday + ahw.saturday AS CHAR(5)) "Hours worked", CAST (((ahw.sunday + ahw.monday + ahw.tuesday + ahw.wednesday + ahw.thursday + ahw.friday + ahw.saturday)* a.HourlyRate) AS DECIMAL(7,2)) "Pay" FROM attendant_hours_worked ahw, attendants a WHERE ahw.week ='2009-04-05' AND ahw.AttendantID = a.AttendantID;

9 Example Output


Download ppt "By Justin LeBourdais. Description Designed for my mother’s business Small updateable database for her clients and employees Designed for ease of use,"

Similar presentations


Ads by Google