Click here to Skip to main content
15,907,497 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
A patient comes into a medical laboratory, the patient is either referred by Doctor, or from HMO or he/she just walk in(self). Both Doctor and HMO has information specific to them like doctor may have(doctor name, hospital, phone no etc), hmo may have (hmo name, hmo address etc). so the user will select from dropdown for (Doctor, HMO, Self). Two things needed,
1. how many table(s) will i create and
2. their relationshiop

What I have tried:

I created referraltype table(refid, ref name, status)
i also create Doctor table(Doctor ID, Doctor name, Doctor Phoneno, Hospital), HMO table (HMO name, HMO address, patient HMO ID, patient unit etc)
Posted
Updated 16-Dec-17 7:14am
Comments
________________ 17-Dec-17 1:40am    
Try to think about common things:
Not HMO and Doctor tables, but PatientReferer - because it has same fields - Name etc.
________________ 17-Dec-17 1:59am    
Types of data also should not be freeze in static construction -
So you need to have table "PatientRefererTypes" - and than you can have rows in this table: "Doctor", "Self", "HMO", "Ambulance"....
________________ 17-Dec-17 2:03am    
Than you should undestand tha Registration DB has two big categories of data - "Master" data, and Documents.
Master data - it is PatientRefererTypes table (have limited amount of rows, define non-concrete thing) and so on, Documents - it is "Patients" table - many concrete patients every day.
________________ 17-Dec-17 2:07am    
Master data - Table of "PatientSex". :-)
Male,Female, other...
It is interesting! If not for you - you have selected wrong profession.

You will create many tables. Some will have a 1 to 1 relationship. Some will have 1 to many. Beyond that, we can't get more specific because you are going to be the one responsible for gathering the requirements.
 
Share this answer
 
We're not here to do your home work for you. This is up to you to determine and I doubt this is everything that needs to be in the database.

If this isn't homework and is an actual application for production, you don't have the skill set to write it yet if you're asking these very basic questions.
 
Share this answer
 
Comments
________________ 17-Dec-17 1:37am    
Hi! When you say "We" - what do you mean? How many are you?
This is second time when I meet on this site such opinion...
Am I miss a role - "Doing homework is forbidden!" ? Where?
:-\
Dave Kreskowiak 17-Dec-17 8:36am    
We: All of the "regular" volunteer contributors who answer questions around here.

Is doing homework forbidden? No. Doing it FOR YOU is. You won't really learn the decision making process to get to any answer. You're either going to find an answer that works for your requirements or you're not. In either case, you're going to learn something, but you're going to have to make mistakes in order to move forward, to learn why a particular path didn't work. You're not going to get that information when someone does you're work for you or only takes you down the correct path.
________________ 18-Dec-17 2:42am    
Regular volunteer or mentor-professor?
I came to this forum to answer to questions I can answer and get the rating.
It is kind of online game for me. Why not?
Source of question - this is not my problem. But I feel disappointed when my correct code was deleted, because it is probably homework for lazy student.
Well, if you so social oriented, and want to learn the others how to live, be smart enough to do it gently. I even do not speak about loosing new users. What they will do, when instead of answer to "stupid" question on this "smart" (or snob?) forum they will read "Solution 1 - Go away lazy student! We see that you!"?
Dave Kreskowiak 18-Dec-17 8:14am    
Doing their homework for them doesn't teach them the most important piece: how to fail successfully. How to learn from their mistakes. They have to learn how to identify the path their on being the wrong one and identify other paths.

Your answers being deleted, aren't being deleted. They're being voted down because they're wrong or inappropriate, like doing someones homework for them. It takes multiple people to flag your answer as bad for it to disappear, and not just one or two votes.

If you're doing this just to get the meaningless rating, you're doing this for the wrong reasons.
________________ 19-Dec-17 2:44am    
So you judge somebody only by you opinion about what is right and what is wrong?
How do you know, who is student? According text of message? Who gave you right to be The Great Censor?
Pay attention - I even do not suggest you to delete your off-topic "Solution1", it is not my problem also, but I do suggest - next time write "I am not here" instead of "We're not here".

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900