-->-----Original Message----- -->From: Bruce Feist [mailto:[EMAIL PROTECTED] -->Sent: Friday, June 27, 2003 3:51 PM -->To: Dathan Vance Pattishall -->Subject: Re: How can a single row with a single column represent 2 values -->without bitwise data representation --> -->Dathan Vance Pattishall wrote: --> -->> -->>Say you have a column in a search table by the name of politics. -->> -->> --> -->>So, my question is how can multiple values for a single field get -->>represented in a single row and receive the benefits of an index? How -->>can this data be represented? -->> --> -->I don't think that there's a perfect answer for your problem. One -->possibility would be to break the values out into multiple columns, one -->for each view, and have indexes on each of those columns, or at least -->the views that you consider most important. It might help to make them -->compound indexes, with each including several views that you think are -->likely to be searched on together.
Compound indexes do not work with the OR sql statement across different columns. Doing the bitwise query essentially allows for the OR. If I'm wrong please some one let me know, I haven't seen it work yet. Also imagine using this approach on 16 different questions-politics, social background, religion, etc. This would be 16*32 columns such that 32 is the number of possible answers for each of the 16 questions. --> --> -->However... aren't you worried that a 'politics' table is likely to be -->corrupt? <g> Funny --> -->Bruce Feist --> -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]