Forum Replies Created

Viewing 15 posts - 1 through 15 (of 29 total)

  • RE: sp_executesql : Procedure expects parameter '@statement' of type 'ntext/nchar/nvarchar'.

    mayank.and.friends (6/10/2009)


    Sql string should be always either ntext/nvarchar/nchar.

    So ,please check type of sql query variable as nvarchar():w00t:

    Thank you! That solved my problem.

  • RE: Unable to shrink transaction log - could not locate files

    I was having the same issue. I could not execute the shrink command on my logical log file name when the name was different in sys_database_files and sys_master_files. ...

  • RE: SP3

    I just finished installing SS2005 SP3 Standard Edition for two instances after a 1/2 day figuring out why one instance (the default MSSQLSERVER) was failing to update.

    I was getting the...

  • RE: UPDATE SET =NULL running over an hour

    Matt, thank you for the range table fix. I implemented that code and also the IF EXISTS and it ran at 28:43. It seems the fastest I can...

  • RE: UPDATE SET =NULL running over an hour

    The member ids sometimes do have alphanumeric characters but should never have any symbols, ie. "[" and ":"; so I like the first way you populated #ranges. I will...

  • RE: UPDATE SET =NULL running over an hour

    Matt Miller (12/3/2008)


    Here's an example of walking the clustered index:

    drop table #ranges

    ;with AlphanumericCTE as (

    select

    char(N) digit,

    char(N+1) nextdigit

    from tally where

    n between 48 and 57 or --digits 0...

  • RE: UPDATE SET =NULL running over an hour

    Jonathan Melo (12/5/2008)


    There are some things you might want to change on your last snippet, even before Jeff gives his code back.

    First off, your temp table shouldn't have the key...

  • RE: UPDATE SET =NULL running over an hour

    Jeff Moden (12/3/2008)


    My recommendation would be to simply drop the indexes that have the two update columns in them and add them back in after the update. Also, Claim_Key...

  • RE: UPDATE SET =NULL running over an hour

    Matt Miller (12/4/2008)


    Did you ever try my idea on? Just curious what you ran into.

    Hi Matt,

    I'm still working on Jeff's solution. It takes a while to run these...

  • RE: UPDATE SET =NULL running over an hour

    Lynn Pettis (12/3/2008)


    May I ask another dumb question? If you are going to update these fields using another procedure, why are you trying to set them to null, why...

  • RE: UPDATE SET =NULL running over an hour

    Lynn Pettis (12/3/2008)


    Here is another idea. The first update will take about 49 minutes (as seen earlier), but the second should actually run faster!

    declare @BatchSize int;

    set @BatchSize = 10000;

    while...

  • RE: UPDATE SET =NULL running over an hour

    Jeff Moden (12/3/2008)


    I see a bunch of stuff in that code snippet that I think is working against you. Please post the real table creationtion statement for the table...

  • RE: UPDATE SET =NULL running over an hour

    Jeff Moden (12/2/2008)


    One more thing... you're updating the same columns that you have in your criteria. Sometimes, and it's again unpredictable, that will cause a recompile for every row...

  • RE: UPDATE SET =NULL running over an hour

    Matt Miller (12/3/2008)


    Lynn Pettis (12/3/2008)


    Never mind my post above, it won't work. I am having a brain dead day here at work and it is seeping over to here....

  • RE: UPDATE SET =NULL running over an hour

    Lynn Pettis (12/3/2008)


    Doug (12/3/2008)


    Thanks Lynn for your input, but it's not helping me much. I ran the script you posted and the 1st statement had 213 batches and took...

Viewing 15 posts - 1 through 15 (of 29 total)