Forum Replies Created

Viewing 15 posts - 16 through 30 (of 40 total)

  • RE: Execute a table of statements

    I need to cite where I got this trick from, but try this:

    DECLARE @stmts TABLE (id INT IDENTITY, stmt NVARCHAR(MAX), PRIMARY KEY (id)) -- your table

    insert into @stmts (stmt)

    select 'print...

  • RE: Transaction Confusion

    Word!

    Thanks. I didn't think about that before. That actually explains the behavior in my actual code.

    But I'm still curious if you know off hand any documentation that states exactly what...

  • RE: Transaction Confusion

    @@version=Microsoft SQL Server 2005 - 9.00.4211.00 (Intel X86) Jan 30 2009 13:43:44 Copyright (c) 1988-2005 Microsoft Corporation Enterprise Edition on Windows NT 5.2 (Build 3790:...

  • RE: Transaction Confusion

    Ok, This is the actual problem I think I am having with my code. I've seen other people write it this way before, so I can't understand why it's wrong/

    CREATE...

  • RE: Transaction Confusion

    Yes that does help.

    Is there a reference anywhere as to what errors a CATCH traps exactly? I was under the impression it was almost if not all errors.

    Also, if you...

  • RE: PIVOT question, I think?

    I'm a moron.

    Thanks for the help.

  • RE: PIVOT question, I think?

    Good good,

    Whenever I try these with the actual table, I get the following error:

    Msg 8167, Level 16, State 1, Line 1

    The type of column "app_sys_group_cde" conflicts with the type of...

  • RE: PIVOT question, I think?

    I'm guaranteed to only deal with one row at a time - We're still working out the exact structure of how the data comes in and all but it's not...

  • RE: Approving Changes

    The pain to wordcount ratio on that post was obscene.

  • RE: Approving Changes

    That solution makes a lot of sense. Here's something I've been thinking about:

    I will place a trigger on the database (actually on every table) and anytime a user executes an...

  • RE: Approving Changes

    GSquared, you're on the right track.

    A simple pending flag like that wouldn't solve the issue of records that were, updated.

    Maybe a multi-option flag, such as

    0 = Live or production record

    1...

  • RE: Approving Changes

    Not quite what I was looking for.

    What I'm looking for is help designing a database in which changes to any of the tables (inserts, updates, deletes) are not applied until...

  • RE: compacting a numbered list

    Out of curiosity, what would you have suggested?

  • RE: compacting a numbered list

    I have a table of applications my organization uses, and unlike parents, my organization doesn't love them all the same.

    These applications were ordered by their recovery time but the list...

  • RE: compacting a numbered list

    Perfect, thanks!

Viewing 15 posts - 16 through 30 (of 40 total)