Forum Replies Created

Viewing 15 posts - 571 through 585 (of 702 total)

  • RE: There Must Be 15 Ways To Lose Your Cursors... part 1, Introduction

    Thomas (4/15/2009)


    Couple of very simple solutions.

    First one is SQL 2005/2008 only, won't work in 2000:

    create table dbo.Numbers (Number int primary key);

    go

    insert into dbo.Numbers (Number)

    select top 10000 row_number() over (order by...

  • RE: Multi Column Sort

    Peso,

    I'm not sure that I'm following your toll-booth analogy properly. I don't see how it fits with the data you posted as coming from the OP:

    ...

  • RE: Multi Column Sort

    Christopher Stobbs (4/9/2009)


    Am I correct in saying the values need to stay in the same rows?

    or could I sort this sample as follows:

    Sample

    Col1 Col2 Col3

    9 ...

  • RE: Multi Column Sort

    OK. If the puzzle's rules specify that the given data always has increasing values in the respective columns of each row, so be it. Does that affect one's...

  • RE: Multi Column Sort

    RBarryYoung (4/8/2009)


    . . . .

    1) When the rows are "in order", values will monotonically increase left to right and top to bottom.

    2) This places implicit restrictions on the...

  • RE: Multi Column Sort

    Since this seems to be a classic example of (whose signature line has this?) "You need an answer? NO. You need a question.", I'd like to offer a hypothetical...

  • RE: Annoying NULLs

    Bravo!! Excelent QOD. I don't mind admitting I had wrong answers because I did learn something. And that is the point, isn't it?

  • RE: Multi Column Sort

    Christian Buettner (4/4/2009)


    jsanborn (4/2/2009)


    Since this was posted for a community of database professionals, I didn't think a great deal of detailed explanation was needed just like I didn't think it...

  • RE: Are the posted questions getting worse?

    Bob Hovious (4/2/2009)


    ......If each of the men paid only 90 bucks (100-10) and 3*90 = 270, and the bellboy kept 20 for a tip, that's only 290 out of the...

  • RE: Multi Column Sort

    Chris Morris (4/3/2009)


    GSquared (4/3/2009)


    Anyone else have any ideas on this?

    There were two other ideas which I've not had time to follow up yet. The first was to derive an average...

  • RE: Are the posted questions getting worse?

    GSquared (4/2/2009)


    This is the kind that gives me hope:

    http://www.sqlservercentral.com/Forums/Topic688912-149-1.aspx

    This is the kind that drives me to The Thread:

    http://www.sqlservercentral.com/Forums/Topic688302-338-1.aspx

    I keep going on the second type because of the first type.

    My goodness!!!!...

  • RE: Can't use column number in GROUP BY?

    Stef,

    What am I missing here? Why do you say "Sound like changing it doens't really simplify it..."?

    Taking the suggestion of Ramesh and wrapping the case statement in a CTE...

  • RE: passing multiple parameters to a stored proc

    David,

    This is an interesting challenge. I'd like to understand it better, so have two questions.

    So you can see how I'm looking at it, code that I've used for optional...

  • RE: How to get top 10 records sum gropued by One colum (USERID)

    Vijayd,

    Glad to have helped. (It is a bit ironic that you posted in the SQL2000 forum without noticing and that I responded here, equally oblivious to the greater context).

    Your solution...

  • RE: Are the posted questions getting worse?

    Alvin Ramard (3/30/2009)


    GilaMonster (3/30/2009)


    Lynn Pettis (3/30/2009)


    Just what do the users expect us to do???

    Read their minds, pull out a magic wand and make the nasty error go away, of course.

    😉

    i.e....

Viewing 15 posts - 571 through 585 (of 702 total)