|
Posted by Erland Sommarskog on 10/18/71 11:29
--CELKO-- (jcelko212@earthlink.net) writes:
>>> We have no idea what business problem PromisedOyster has, so it's quite
pointless to cram that calender table down this throat. <<
>
> Okay, what are the odds that he lives in a world without time and aksed
> this question?
Few people live in a world without food and water. Does that mean
that as soon as we design a database, we must have food and warer in ir?
> So the right answer to temporal problems change depending on your
> privileges? No, it does not. The abiltiy to do the right thing might
> change depending on your privileges, but the answer does not. And as a
> professional it is your duty to speak the truth.
As a professional it is our duty to help people with the problems they
present. Not the problems we invent outselves. All we know is that
Promised Oyster needs is a temporary table of some sort that gives
him all dates in an interval.
It is also our professional duty to behavely politely and respectfully
towards people.
>>> Holidays etc? Yes, there is table for this as well, but it only has
entries for Mon-Fri that are not business days, and it's maintained by
users. <<
>
> Keeping temporal data in two places as you proposed sounds like
> attribute splitting. Can you tell me why a holiday is a logically
> different kind of thing from anyother date?
The two tables serves different purposes. The table with all the dates
puts no attributes on the dates, and is only a help table for some
operations. The other table lists only holidays. Neither that table
has any other data beside the primary key, beside auditing data. But
there is an important difference between the two tables, let's see if
you can spot it!
--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp
Navigation:
[Reply to this message]
|