|
Posted by --CELKO-- on 05/17/06 15:28
>> I have an attribute that determines the unit of something,e.g. the size of using "mm" , the length of using "seconds" and something others may using "n-page", so ,which data type should I use. the "nvarchar" or others? <<
You need to learn how a relational design works. What meaningful name
could you give such a column? "some_kind_of_unit" or "don't_know_unit"
or "could_be_anything" is a bit vague. Since seconds cannot be
transformed into volts, etc. this column is in violation of !NF -- it
holds several totally different things, like field in a file system.
Units of measure are part of an attribute's value, not an attribute.
You are confusing data and meta-data. Get of a copy of SQL PROGRAMMING
STYLE or SQL FOR SMARTIES and read the chapters on scales and
measurements, and the design of encoding schemes.
Navigation:
[Reply to this message]
|