update query the where condition's is large (upto 20 chars)

  • Dear All,

    If in update query the where condition's is large (upto 20 chars) then update is not working..

    update login set pass_word='763893hj47hr84n84jr8fj4f89u4jf4u84fu84' where oldpass_word='8d8r57h4r774gqt649rj90rkjdfnhnd9' ;

    Here oldpass_word has a large data.Now if I make it short as :

    update login set pass_word='763893hj47hr84n84jr8fj4f89u4jf4u84fu84' where oldpass_word='8d138ww' ;

    Now it's executing..I have tried it in sql server2000...

    All datatypes are in nvarchar...

    Thanks

  • Whats the size of datatypes

    "Keep Trying"

  • Dear

    Password has 50 chars

    oldpass_word has 200 chars

    Thanx

    Thanks

  • Are you sure that such a value '8d8r57h4r774gqt649rj90rkjdfnhnd9' exists in the column.

    What does select pass_word from login where oldpass_word='8d8r57h4r774gqt649rj90rkjdfnhnd9' return?

    "Keep Trying"

  • When you say "update is not working", what exactly do you mean?

    Throws an error?

    Runs forever?

    Updates no rows?

    Something else?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • Dear

    I mean ,query executed successfuly, (0) rows affected message, comes.

    Thanx

    Thanks

  • What's the definition of the login table?

    If you run the query that Chirag posted, what do you get?

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

Viewing 7 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic. Login to reply