If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Oracle > What to do when the same entiry has diffirent attributes

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 07-27-10, 01:15
sayyed_kamran sayyed_kamran is offline
Registered User
 
Join Date: Jun 2009
Posts: 22
What to do when the same entiry has diffirent attributes

I am going to develope a eHelpDesk. This system is to resolve user issues and also to provide them diffirent services.

Like for example if my Photo copier is out of order, I will raise a ticket, by selecting a predefined servie "Maintinance of photo copier" and my problme will be putted forward/resolved by the concerned technician.

I have designed a services table like this

ServiceID
ServiceName
ParenetServiceID
ServiceCode

and so on.........

Now there are some special attribute(s) of each and every service that is specific to that service only.
EXamples:
If the service is "Repair of photocopier" it has an attribute "Counter of photo copier"
And if the service is:
"Installation of Software" It has a unique attribute:
"Asset Traking ID of the computer on which is going to be installed"

There are hundreds of services each having unique attributes. How I can accomodate this requirement in my db Design.

Plz help, our whole project is at risk.
Reply With Quote
  #2 (permalink)  
Old 07-27-10, 01:34
anacedent anacedent is offline
Registered User
 
Join Date: Aug 2003
Location: Where the Surf Meets the Turf @Del Mar, CA
Posts: 6,155
>How I can accomodate this requirement in my db Design.

Third Normal Form!
__________________
You can lead some folks to knowledge, but you can not make them think.
The average person thinks he's above average!
For most folks, they don't know, what they don't know.
Reply With Quote
  #3 (permalink)  
Old 07-27-10, 06:59
sayyed_kamran sayyed_kamran is offline
Registered User
 
Join Date: Jun 2009
Posts: 22
Thanks for your post!

I know what is third normal form, But will you plz explain it a little bit in my case, As the difficulty in my case is the special attributes depends on an instance of entity, not on the entity itself.

"Service" iz an entity in my case having attributes like
serviceName
sericeCode
serviceParent......

But a special attribute "Counter of photo copier" is an attribute of and instance ("Counter of the copy machine") of the entiry. This attribute has nothing to do with an other instance "Installation of software" of the same entity "Serive".

I cant understant how to apply third normal form to this whole situation.
Reply With Quote
  #4 (permalink)  
Old 07-27-10, 09:10
dav1mo dav1mo is offline
Registered User
 
Join Date: Dec 2007
Location: Richmond, VA
Posts: 779
how bout something like:
pk
typ_o_srvc
value
Reply With Quote
  #5 (permalink)  
Old 07-27-10, 11:07
LKBrwn_DBA LKBrwn_DBA is offline
Registered User
 
Join Date: Jun 2003
Location: West Palm Beach, FL
Posts: 2,413
Cool Data models anyone?

Quote:
Originally Posted by sayyed_kamran View Post
Blah, blah, blah...
I cant understant how to apply third normal form to this whole situation.
Check out this Help Desk Data Model.
__________________
The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb
Reply With Quote
  #6 (permalink)  
Old 08-02-10, 07:23
sayyed_kamran sayyed_kamran is offline
Registered User
 
Join Date: Jun 2009
Posts: 22
It will not work for me. I need special attirbutes with each and every service
Reply With Quote
  #7 (permalink)  
Old 08-04-10, 06:10
NaveenK NaveenK is offline
Registered User
 
Join Date: Aug 2010
Location: Bangalore
Posts: 7
Try this.

Create a table which will have the common attributes of all services.
Ex:

MainTable - service_id, service_name, service_code ....

then create a one more table which will have 4 columns

SecondaryTable - pk, service_id, attribute_name, attribute_value.

In this way you can store any number of custom attributes for a service type. This is like map in java.
Reply With Quote
  #8 (permalink)  
Old 08-04-10, 06:40
sayyed_kamran sayyed_kamran is offline
Registered User
 
Join Date: Jun 2009
Posts: 22
Thnks for your reply, I am going to try this solution.
Reply With Quote
  #9 (permalink)  
Old 12-24-10, 02:54
sayyed_kamran sayyed_kamran is offline
Registered User
 
Join Date: Jun 2009
Posts: 22
Can I user Specilization in my Case? Will it be physible to use it here?
Reply With Quote
  #10 (permalink)  
Old 12-24-10, 10:52
anacedent anacedent is offline
Registered User
 
Join Date: Aug 2003
Location: Where the Surf Meets the Turf @Del Mar, CA
Posts: 6,155
eschew obfuscation, espouse elucidation

since it is your database, you can (ab)use it any way you desire to do so.
__________________
You can lead some folks to knowledge, but you can not make them think.
The average person thinks he's above average!
For most folks, they don't know, what they don't know.
Reply With Quote
  #11 (permalink)  
Old 12-31-10, 07:03
sayyed_kamran sayyed_kamran is offline
Registered User
 
Join Date: Jun 2009
Posts: 22
Quote:
Originally Posted by anacedent View Post
eschew obfuscation, espouse elucidation

since it is your database, you can (ab)use it any way you desire to do so.
But i wanted to know the best possible solution.
Reply With Quote
  #12 (permalink)  
Old 12-31-10, 08:55
anacedent anacedent is offline
Registered User
 
Join Date: Aug 2003
Location: Where the Surf Meets the Turf @Del Mar, CA
Posts: 6,155
>But i wanted to know the best possible solution.

First make it work, then make it fancy.

Trying to optimize an implementation that does NOT work, is a waste of effort.
__________________
You can lead some folks to knowledge, but you can not make them think.
The average person thinks he's above average!
For most folks, they don't know, what they don't know.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On