Re: Lots of Bits
From: Jeremy S. (A_at_B.COM)
Date: 01/19/05
- Next message: IPGrunt: "Re: Call ASP.NET application pages from old ASP page"
- Previous message: IPGrunt: "Re: Lots of Bits"
- In reply to: Jack Burton: "Re: Lots of Bits"
- Next in thread: IPGrunt: "Re: Lots of Bits"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 18 Jan 2005 20:56:59 -0800
Okay, your "tally" makes more sense. IMHO, you're getting into some
interesting trade-offs with this "binary value" stored in the db and it
comes down to what you are comfortable living with (like many design
considerations). If the number of binary columns is large and you are
searching on them, then you should also index them. This has some
maintenance and performance and complexity implications. Compared with one
integer column that holds some unique value, then the query is simplified
and performance is perhaps increased for the database. Of course a database
purist might frown upon it for more theoretical purposes as well as the many
practical purposes related to maintaining the unique int value that has your
application-specific meaning. I suspect that if you posted this in the
microsoft.public.sqlserver.programming group that you'd get some intersting
perspective and rationalle beyond what I pointed out (which you probably
were aware of before I pointed it out). As for my opinion; I'd most
definitely lean toward keeping the bits in their own columns... it just
gives you so much more flexibility in extracting information. You can always
create and programmatically maintain a separate denormalized table that
could have your special "tally" column and then query that table for your
current searching/reporting purposes. This gives you the best of both worlds
and is possibly the easiest solution to modify in the future because you
always have the original bits to go back to while your queries can be
simpler and perform fewer (perhaps zero) joins and therefore run faster
because they are hitting a single denormalized table. You get the idea.
Good Luck!
"Jack Burton" <jack-b@humlog.com> wrote in message
news:%23aCy8vd$EHA.3708@TK2MSFTNGP14.phx.gbl...
>
> Yes sorry I was a bit vague.
>
> These values are used for filtering purposes e.g. searching for
> customers who best matches criteria set out in a marketing campaign i.e.
> match customer filter values with campaign filter values.
>
> Hope that make sense.
>
> When I say 'clarity' I just mean the customer table was becoming massive
> so I thought I'd move the filter values into a another table (yes it
> requires another join - i may change it back)
>
>
> I definitely used the wrong word in 'tally' - sorry. I mean representing
> all bit values as one binary value. This value can then be stored in the
> database (as a decimal or hex). If one value is just say changed then a
> new binary is formed and hence a new value in the database.
>
> Does this make any sense?
>
> This is just a 'throw out there' question as i would be interested in
> opinions.
>
> Cheers,
> Jack
>
>
>
> *** Sent via Developersdex http://www.developersdex.com ***
> Don't just participate in USENET...get rewarded for it!
- Next message: IPGrunt: "Re: Call ASP.NET application pages from old ASP page"
- Previous message: IPGrunt: "Re: Lots of Bits"
- In reply to: Jack Burton: "Re: Lots of Bits"
- Next in thread: IPGrunt: "Re: Lots of Bits"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|