Forum Replies Created

Viewing 15 posts - 241 through 255 (of 427 total)

  • RE: Traversal in Columns

    See, that is why we ask you to provide us with a: a script creating the table and some sample data plus b: the expected output, so we know what...

  • RE: Traversal in Columns

    Can you give the solution here so that we may all learn from it?

  • RE: Traversal in Columns

    An example and some test data would have been helpful here. But I think what you are looking for is a combination of a cross apply and a union all,...

  • RE: How to get output in following formats

    Your image link is broken so you will probably not get any correct answers. But don't mind fixing that. Instead, please click 'Posting Data Etiquette' in my footer text and...

  • RE: Script Help Please!

    Sorry, double error: posting the wrong link to the wrong person. Thanks for posting the correct link.

  • RE: Script Help Please!

    HowardW (9/27/2011) They're different as OR's are evaluated last, so you're effectively saying all of the AND conditions are true or the OR condition

    Please read this page on Operator Precedence...

  • RE: grouping issue (I think?)

    Can you please add the DDL (= create table statement) too? So we can see the proper types, keys, foreign keys, indexes and load the data into it?

    Have a...

  • RE: grouping issue (I think?)

    Ok, first some remarks on that code (I'm trying to be constructive here, not listing this to put you down):

    - numeric constants are not enclosed in quotes (''), i.e. '8'...

  • RE: grouping issue (I think?)

    You'll probably need a better key than 'month_name' to group by (maybe include a year?), but this does what you asked for:

    select

    (

    ...

  • RE: error handling

    Sudhir Dwivedi (9/26/2011)


    For continuously calling usp_exampleproc until an error occurs you could of course use a while loop:

    Why would one like to do so?? I can't understand.:unsure:

    OP has to answer...

  • RE: error handling

    For continuously calling usp_exampleproc until an error occurs you could of course use a while loop:

    DECLARE @result INT = 0;

    WHILE @result...

  • RE: error handling

    Or, by changing the order a little bit, you can make the outer catch block catch first procedure's errors, while the 2nd procedure's errors are caught by the inner catch....

  • RE: error handling

    is this inside a stored procedure? If it is, you can use a return statement within the catch block to return to the caller without executing the remaining code.

    CREATE PROCEDURE...

  • RE: SQL 2008 - T-SQL query assistance

    Jeff Moden (9/25/2011)


    Heh... that's a hell of a change from the first-blush example. 😀

    Actually, I have to admit that I'm not the Topic Starter on this one. I have -not...

  • RE: SQL 2008 - T-SQL query assistance

    The "process" is to analyze the set of expressions and generate static code from it. The expressions are the definitions for an engine processing data changes in near-real-time (using SQL...

Viewing 15 posts - 241 through 255 (of 427 total)