1 / 9

Nursing Home Database

This database was created specifically for my mother's nursing home business, aimed at managing clients and employees effectively. It is a small, easily updateable system designed with user-friendliness in mind, ensuring that most necessary codes are pre-written for convenience. It provides a functional and straightforward interface, though it does have some incorrect data relationships and naming convention issues. Key lessons learned include the importance of adhering to data modeling conventions and maintaining detailed notes on SQL code for future revisions.

Download Presentation

Nursing Home Database

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Nursing Home Database 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_workedahw, attendants a WHERE ahw.week ='2009-04-05' AND ahw.AttendantID = a.AttendantID;

  9. Example Output

More Related