SQL Server Performance

Distinct count on text measures

Discussion in 'Analysis Services/Data Warehousing' started by saveriop, Sep 26, 2003.

  1. saveriop New Member

    How can I obtain a distinct count aggregation on a text fact table coloum?

    I tried to add a CheckSum calculated coloumn to my fact table, but OLAP return strange results.
  2. Twan New Member


    Pretty sure that you can't... Unless you convert it to varchar(8000) in the query...

    Cheers
    Twan
  3. yanke_zulu New Member

    I also want to distinct count text file

    How do we use varchar(8000) in query , could you please explain

    thx
  4. Twan New Member


    you can do a
    select count( distinct convert( varchar(8000), textcol ) ) from table

    Though this will only check the uniqueness of the first 8000 characters

    Cheers
    Twan

Share This Page