• porkins
    link
    fedilink
    arrow-up
    2
    ·
    1 year ago

    Distinct is really only meant to be used like count(distinct x). If you have dupes in your output then you didn’t understand the cardinality of the data. He claims that his method is faster that just grouping by the account in the orders table. If that’s the case then SQL server is terrible.