![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi folks. I have a problem with wrapping my mind into the 'right' wrinkles. I need to come up with a database design in SQL/MSAccess, since that's the tool that is available to me. The subject of the database is an inventory of electronic instruments, and the objective is to maintain a status log of these instruments. The naive idea is: - Instrument ID - Instrument status (active / stand-by / inactive) - Instrument location (room / shelf / position) The above ought to be valid for all instruments. Then there are a few instruments that need to be calibrated before use. These need to have some additional fields: - Calibration status ( OK / not calibrated ) - Calibration data ( varies with type of instruments ) The problem is the latter two fields. Only a few instruments need to be calibrated at all; and the calibration data varies with the exact type of instrument. A microphone might need a gain factor from sound pressure to voltage; a GPS position sensor might need an (x,y,z) location plus orientation along three axes. The above would be almost trivial to implement in an object-oriented context (well, this si my first attempt at databases at all - my experience is with OO programming), but I don't see how to come up with a table-based database design. Any general ideas on how to design a SQL database around such constraints? Dr. C. |
#3
| |||
| |||
|
|
Hi folks. I have a problem with wrapping my mind into the 'right' wrinkles. I need to come up with a database design *in SQL/MSAccess, since that's the tool that is available to me. The subject of the database is an inventory of electronic instruments, and the objective is to maintain a status log of these instruments. The naive idea is: - Instrument ID - Instrument status (active / stand-by / inactive) - Instrument location (room / shelf / position) The above ought to be valid for all instruments. Then there are a few instruments that need to be calibrated before use. These need to have some additional fields: - Calibration status ( OK / not calibrated ) - Calibration data ( varies with type of instruments ) The problem is the latter two fields. Only a few instruments need to be calibrated at all; and the calibration data varies with the exact type of instrument. A microphone might need a gain factor from sound pressure to voltage; a GPS position sensor might need an (x,y,z) location plus orientation along three axes. The above would be almost trivial to implement in an object-oriented context (well, this si my first attempt at databases at all - my experience is with OO programming), but I don't see how to come up with a table-based database design. Any general ideas on how to design a SQL database around such constraints? Dr. C. |
#4
| |||
| |||
|
|
dr.coff... (AT) gmail (DOT) com wrote: Hi folks. I have a problem with wrapping my mind into the 'right' wrinkles. .... Any general ideas on how to design a SQL database around such constraints? Dr. C. Those are mostly trivial data modelling problems. Have you read anything on data modelling, normalization, joins? |
#5
| |||
| |||
|
|
On 8 Jun, 18:25, Bob Badour <bbad... (AT) pei (DOT) sympatico.ca> wrote: |
|
Those are mostly trivial data modelling problems. Have you read anything on data modelling, normalization, joins? Yes, I have. Well, 'browsed' is a better term, as the objective is to get a working demo system up in a hurry. |
|
As age progresses, I'm more and more inclined to skip reading what is not immediately percieved as useful, so presumably I don't see the forest for the trees. Databases are the solution to the problem at hand; I just don't have the hands-on experience (yet) needed to come up with a working system. |
#6
| |||
| |||
|
|
Hi folks. I have a problem with wrapping my mind into the 'right' wrinkles. I need to come up with a database design in SQL/MSAccess, since that's the tool that is available to me. The subject of the database is an inventory of electronic instruments, and the objective is to maintain a status log of these instruments. The naive idea is: - Instrument ID - Instrument status (active / stand-by / inactive) - Instrument location (room / shelf / position) The above ought to be valid for all instruments. Then there are a few instruments that need to be calibrated before use. These need to have some additional fields: - Calibration status ( OK / not calibrated ) - Calibration data ( varies with type of instruments ) The problem is the latter two fields. Only a few instruments need to be calibrated at all; and the calibration data varies with the exact type of instrument. A microphone might need a gain factor from sound pressure to voltage; a GPS position sensor might need an (x,y,z) location plus orientation along three axes. |
#7
| ||||||
| ||||||
|
|
On 8 Jun, 18:25, Bob Badour <bbad... (AT) pei (DOT) sympatico.ca> wrote: dr.coff... (AT) gmail (DOT) com wrote: Hi folks. I have a problem with wrapping my mind into the 'right' wrinkles. ... Any general ideas on how to design a SQL database around such constraints? Dr. C. Those are mostly trivial data modelling problems. Have you read anything on data modelling, normalization, joins? Yes, I have. Well, 'browsed' is a better term, as the objective is to get a working demo system up in a hurry. |
|
As age progresses, I'm more and more inclined to skip reading what is not immediately percieved as useful, so presumably I don't see the forest for the trees. Databases are the solution to the problem at hand; I just don't have the hands-on experience (yet) needed to come up with a working system. |
|
The problem is that I think in OO terms, like classes and inheritance. Decades ago I used to work very hard to get away from arrays and other non-OO data structures associated with procedural programming, and now I am unable to revert my mind to that context. |
|
In particular, I don't recognize OO terminology from what I read, and I am not able to recognize OO concepts from the terminology I do see. As somebody correctly pointed out, I am not used to the problem statement that needs to be used in DB design. |
|
So in the 'naive' problem statement I see an array of objects of classes derived from a base class (in C++ I'd use boost::shared_ptr to access the objects), while I read that SQL is constrained to 'trivial' arrays. The problem is the vast philosophical distance between the two problem statements, that I am unable to bridge. |
|
I'd appreciate any key words to look for when re-reading the material. I'm using Teorey's "Database Modeling and Design: Logical Design", 4th edition. Dr. C. |
#8
| ||||||
| ||||||
|
|
dr.coff... (AT) gmail (DOT) com wrote: On 8 Jun, 18:25, Bob Badour <bbad... (AT) pei (DOT) sympatico.ca> wrote: dr.coff... (AT) gmail (DOT) com wrote: Hi folks. I have a problem with wrapping my mind into the 'right' wrinkles. ... Any general ideas on how to design a SQL database around such constraints? Dr. C. Those are mostly trivial data modelling problems. Have you read anything on data modelling, normalization, joins? Yes, I have. Well, 'browsed' is a better term, as the objective is to get a working demo system up in a hurry. Define 'working'. |
|
As age progresses, I'm more and more inclined to skip reading what is not immediately percieved as useful, so presumably I don't see the forest for the trees. Databases are the solution to the problem at hand; I just don't have the hands-on experience (yet) needed to come up with a working system. Hands-on experience is no substitute for fundamental education. If we had to rely on hands-on experience for multiplication, I doubt anyone would have ever progressed beyond the 12 times tables. |
|
The problem is that I think in OO terms, like classes and inheritance. Decades ago I used to work very hard to get away from arrays and other non-OO data structures associated with procedural programming, and now I am unable to revert my mind to that context. Am I hearing you correctly? You worked very hard to force your brain to think in terms of a single physical computational model? That's unfortunate and must be very limiting. No doubt you will have to work equally hard to overcome that impediment. |
|
In particular, I don't recognize OO terminology from what I read, and I am not able to recognize OO concepts from the terminology I do see. As somebody correctly pointed out, I am not used to the problem statement that needs to be used in DB design. I am not sure what use you would make of OO terminology. It's all rather nebulous, overloaded and imprecise. None of it is any good for communicating much of anything. |
|
So in the 'naive' problem statement I see an array of objects of classes derived from a base class (in C++ I'd use boost::shared_ptr to access the objects), while I read that SQL is constrained to 'trivial' arrays. The problem is the vast philosophical distance between the two problem statements, that I am unable to bridge. Philosophy? |
|
An n-dimensional relation of arbitrary domains is 'trivial'? |
#9
| |||
| |||
|
|
On 8 Jun, 18:25, Bob Badour <bbad... (AT) pei (DOT) sympatico.ca> wrote: dr.coff... (AT) gmail (DOT) com wrote: Hi folks. I have a problem with wrapping my mind into the 'right' wrinkles. ... Any general ideas on how to design a SQL database around such constraints? Dr. C. Those are mostly trivial data modelling problems. Have you read anything on data modelling, normalization, joins? Yes, I have. Well, 'browsed' is a better term, as the objective is to get a working demo system up in a hurry. As age progresses, I'm more and more inclined to skip reading what is not immediately percieved as useful, so presumably I don't see the forest for the trees. Databases are the solution to the problem at hand; I just don't have the hands-on experience (yet) needed to come up with a working system. The problem is that I think in OO terms, like classes and inheritance. Decades ago I used to work very hard to get away from arrays and other non-OO data structures associated with procedural programming, and now I am unable to revert my mind to that context. In particular, I don't recognize OO terminology from what I read, and I am not able to recognize OO concepts from the terminology I do see. As somebody correctly pointed out, I am not used to the problem statement that needs to be used in DB design. So in the 'naive' problem statement I see an array of objects of classes derived from a base class (in C++ I'd use boost::shared_ptr to access the objects), while I read that SQL is constrained to 'trivial' arrays. The problem is the vast philosophical distance between the two problem statements, that I am unable to bridge. I'd appreciate any key words to look for when re-reading the material. I'm using Teorey's "Database Modeling and Design: Logical Design", 4th edition. Dr. C. From your two uses of the word "trivial", I gather you are using it to mean |
#10
| |||
| |||
|
|
The database community can handle this in a couple of ways: 1) Close in on yourself and mock people who do not have the * *insights you have. 2) Recognize the problem and help sort out the misunderstandings * *and snags. Over the past couple of days I have got a clear impression about what approach seems to be preferred by the regulars here. Let me get this straight. You need help from the database community |
![]() |
| Thread Tools | |
| Display Modes | |
| |