Forum Replies Created

Viewing 3 posts - 31 through 33 (of 33 total)

  • RE: PIVOT REQUIRED

    select COLUMN1, COLUMN2,

    sum(case when COLUMN3 =N'P' then COLUMN4 end) as [P],

    sum(case when COLUMN3 =N'Q' then COLUMN4 end) as

    ,

    sum(case...

  • RE: simple and tricky question

    Hi,

    There are good articles by Jeff Moden on this subject

    http://www.sqlservercentral.com/articles/T-SQL/63681/[/url]

    and second part

    http://www.sqlservercentral.com/articles/cross+tab/65048/[/url]

    Kupy

  • RE: Optimize query

    Hi,

    As far as I know, the first choice should be the one for 2 reasons

    1. The first condition give less records

    2. Numeric field is quicker then varchar field

    Kupy

Viewing 3 posts - 31 through 33 (of 33 total)