|
database
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
|
i have a table with 5 million rows. It has a binary column. I am curious
to know if i do a group by on that column, will it be faster if i have it as varbinary rather than binary TIA thx The best way to find out is to try both options and see. It probably
depends on the average length of the items stored. Unless you find a a large difference between the choices, you should probably store the data in whichever format makes the most sense for the information it represents. With binary, everything will be right-padded with 0x00 bytes, so if a trailing 0x00 is meaningful, binary is not going to be useful. Steve Kass Drew University skg wrote: Show quote >i have a table with 5 million rows. It has a binary column. I am curious >to know if i do a group by on that column, will it be faster if i have it as >varbinary rather than binary > >TIA >thx > > > > Thanks!! Steve.
Yes i see the right padding hence i was concerned. Thanks for your input. Show quote "Steve Kass" <sk***@drew.edu> wrote in message news:%23SEMan%23tGHA.4544@TK2MSFTNGP04.phx.gbl... > The best way to find out is to try both options and see. It probably > depends on the average length of the items stored. Unless you find a > a large difference between the choices, you should probably store > the data in whichever format makes the most sense for the information > it represents. With binary, everything will be right-padded with 0x00 > bytes, so if a trailing 0x00 is meaningful, binary is not going to be > useful. > > Steve Kass > Drew University > > skg wrote: > >>i have a table with 5 million rows. It has a binary column. I am curious >>to know if i do a group by on that column, will it be faster if i have it >>as varbinary rather than binary >> >>TIA >>thx >> >> |
|||||||||||||||||||||||