Poor Data model Or good solution?

Results 1 to 3 of 3

Thread: Poor Data model Or good solution?

  1. #1

    Default Poor Data model Or good solution?

    I just starting working on a project for heavy equipment. All heavy equipment for the most part has a few common fields (make, model, serial, etc.). What I would like to be able to do is customize each field defition past the common ones. A good example of this would be a backhoe and a dozer. Both have the common fields, make, model, etc., but a backhoe has tires and a dozer has tracks. My end users are wanting to know the condition for each of these. Now it really does not make sense for me to put a field in my Db named tire_condition when I am really talking about tracks for the dozer(or does it?). At first I thought I could just change the template when it comes out of the Db and when it goes in. But we are working with about 1200 different types of equipment each with specifics past the common fields. <BR><BR>Anyways, My hack of an idea...<BR>When a user goes to put equipment in the Db, ask them what they are putting in. This part of the Db we will control, limited selection (dozer, backhoe, etc.). If the user chooses a dozer, we would load the names for the specifics into the form. what we would end up with is someithing like this for fields in the table.<BR>FIELD_NAME VALUE<BR>Make CATERPILLAR <BR>Model 1506<BR>Year 1998<BR>Desc Dozer<BR>field_1 Track Condition (hidden in the form)<BR>field_2 user enters track condition<BR>field_3 Read Pin Condition (hidden in the form)<BR>field_4 user enters pin condition<BR><BR>I dont feel real good about doing this, but the only thing else would be to make lots of tables. I am way open to ideas on this one.<BR><BR>thanks for any input on this,<BR>Drug_dealer<BR><BR>

  2. #2
    Rob Guest

    Default RE: Poor Data model Or good solution?

    This would be my suggestion.<BR>Make as many common fields as you can. For example, a field named navigation could describe the movement. i.e. tires, tracks, jet rocket, etc......<BR><BR>Then make a field for misc and put all the other misc data in it.<BR>If you want to put it in forms, put it in textareas as opposed to input forms or just display it.<BR><BR><BR>Rob

  3. #3
    Join Date
    Dec 1969

    Default RE: Poor Data model Or good solution?

    You could have an extensions table, and then an extension values table. This would mean that you would have to do much less "design" updates and could just modify these tables when you have additional fields.<BR><BR>i.e.<BR><BR>Categories:<BR>Category _ID<BR>CategoryName (e.g. Dozer)<BR><BR>HeavyEQ:<BR>EQ_ID [PK]<BR>Category_ID<BR>Make<BR>Model<BR>etc. (common fields)<BR><BR>Extensions:<BR>ExtensionID [PK]<BR>Category_ID [FK] <BR>ExtensionFieldName (e.g. track condition)<BR><BR>HeavyEQExtensions:<BR>EQ_ID [FK]<BR>ExtensionID [FK]<BR>Value <BR><BR>To query it would be more complex, but this would definitely be more extensible.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts