Forum Replies Created

Viewing 15 posts - 406 through 420 (of 557 total)

  • RE: formatting varchar as percentage

    Alexander Suprun (11/28/2013)


    Your client application should take care of formatting.

    Sometimes the client application is less suetable for the formatting.

    For example I sometimes do the formatting within SQL-server when serving for...

  • RE: Disk Usage by Top Tables

    This is a rather old thread, so for this question it would have been better to start a new thread.

    I use the numbers always as a rough indication;

    Table Name ...

  • RE: Update Based on Select with Multiple Returns

    Use the following code to just see what is happening:

    --------------------------------------------------------

    -- Actual code to prepare for an UPDATE a Select

    --------------------------------------------------------

    ;with

    A as...

  • RE: sp_generate_inserts

    Sean Lange (10/8/2013)


    I am not really sure what you are trying to do or what the question is.

    Sp_generate_Inserts, generates insert statements from an existing table. For example to create (part)...

  • RE: Update Based on Select with Multiple Returns

    --------------------------------------------------------

    -- Actual code to UPDATE

    --------------------------------------------------------

    ;with

    A as (

    select

    ...

  • RE: Update Based on Select with Multiple Returns

    For this type of problem I like the Windows functions to give each row a number which makes the row unique.

    With CTE the 'double' rows can be removed.

    ...

  • RE: sp_generate_inserts

    Sorry additional,

    I did write:

    I am aware of the 'database task generate scripts'.

    But I do not know how to do this with a scripted command.

    (As with sp_generate_inserts, example:

    sp_generate_inserts My_Table

    )

    sorry...

  • RE: WITH (NOLOCK), allows dirty reads.

    Thanks all,

    Did try the suggested code, and indeed this was different than I expected. Thank you for educating me.

    Thanks,

    Ben

  • RE: WITH (NOLOCK), allows dirty reads.

    Eugene Elutin (8/1/2013)

    It's not just "allows" dirty read. It does exactly perform what is called "dirty reads"!

    For my understanding:

    1. Dirty reads is the reading of data which is not (yet)...

  • RE: Conditional print for testing scripts.

    Eugene Elutin (7/29/2013)

    RAISERROR has in-built token parsing functionality!

    Thanks all for your responses:

    Stop thinking about what you want to do to a print... think, instead, of what you want to do...

  • RE: Conditional print for testing scripts.

    Jeff Moden (7/26/2013)


    Using PRINT for troubleshooting can be a real PITA and the output sometimes doesn't show up until the end of the run instead of as the procedure run...

  • RE: Conditional print for testing scripts.

    Lowell (7/25/2013)

    --fails

    EXEC iSPRINT 'This is a teststring to print time: ' , CONVERT(varchar(112,getdate())

    --works

    EXEC iSPRINT 'This is a teststring to print time: ' , 'when Spongebob','IsOn Nickelodeon'

    But this...

  • RE: Conditional print for testing scripts.

    Lowell (7/25/2013)

    just add EXEC in front of your iPrint calls:

    EXEC iPirnt @Param and you are good to go!

    --------------------------- Wat I am looking for. (This does produce an error).

    EXEC...

  • RE: Impact of DBCC UPDATEUSAGE (0)

    Thanks, we went ahead with this with no problems.

    Thanks again for your input.

    Ben

  • RE: Impact of DBCC UPDATEUSAGE (0)

    ben.brugman (7/4/2013)


    Can this be done online?

    Ben Brugman

    Maybe not the correct question.

    If this is done online will this cause locks over a long duration ?

    Or does it just handle just one...

Viewing 15 posts - 406 through 420 (of 557 total)