Question How to make favorites from records to append them through a cmdButton afterwards

shah141

New member
Local time
Tomorrow, 00:31
Joined
May 6, 2012
Messages
4
Hello everybody and thanks in advance to everyone who will help me find the solution to my question.
I am trying to make some favorites from records in a table so that I may use them afterward in another table. I elaborate my question further as follows..
I have got a tblInvestigations that have all the Investigations' data. It has two important fields InvestID as Primary Key and InvestName for Investigation Names along with other fields. To enter Investigations for patients I use a ComboBox to fetch each Investigation Name. Now there are situations when I have to order same set of Investigations to different patients. for example before any operation I have to order Blood CP, Urine RE, Chest X-Ray etc etc. To make things easier, I want to make some arrangements of favorites (Pre-Op Investigations for the above sited example), so that I may insert multiple investigations with a single click.
I am sure it is possible in Access and VBA but don't know how...
Please help me find the solution. thanks in anticipation.
 
I think that a way to do this is to design 2 more tables:
tblTypesOfInvestigations
ID_TypeOfInvestigation (AutoNumber)
TypeOfInvestigation (Text)

Here you store data like Pre Op on heart, After Op on brain

tblDefaultAnalysess
ID_DefaultAnalyse (AutoNumber)
ID_TypeOfInvestigation (FK , lookup on tblTypesOfInvestigations)
InvestID (FK, lookup on tblInvestigations)

This way, if you wish to insert a set of default investigations all you need is to look at this table and to manage to insert the appropriate set of investigations.

Hope this is a help for you.

For all that will see this post:
Please take also a look HERE.
Thank you !
 
Thanks Mihail for your time and reply.
I think you are guiding me to make many to many relation and then use joining table to fetch data. I will try this and let you know if it works.
But I was thinking of using array to handle this. I try to explain you what is in my mind. I think to build a table tblFavorites with FavoriteID as Primary key (AutoNumber), FavoriteArray (text) to store InvestigationIDs in the form of numbers separated by commas like 1, 3, 15, 21, so on and so forth. Then to fetch Investigation data from tblInvestigations according to this Array.. But unfortunately I am not well conversant with Arrays and their use in such situations.. Is it possible to go as I think., If so then please guide me. Thinks a lot for your response.
 
I think you are guiding me to make many to many relation and then use joining table to fetch data.
Indeed.

I think that your approach should work.
But why to remember the numbers for analyses ?
And what if, at a time, you wish to insert one or more analyses ? The medical knowledge is very dynamic so, this year a set of analyses is OK but the next year should be updated.
I'm pretty sure that your approach is not as ease to use as my one. But is your choice, of course.

On the other hand, I'm also not very comfortable with arrays, so I can't help you.
But I'm sure that someone from here will be able to do.
 
Access is a tool to create and maintain relations between data, but you seem to wish to throw that away and create your own mechanism for managing data. The envisaged advantage of your method over the standard Access tools is what exactly?
 

Users who are viewing this thread

Back
Top Bottom