0

Lock issue occurred when i tried to update a Column of a table with concatenate the same column value with some characters.

UPDATE Templates 
   SET TemplateName = CONCAT("'", (SELECT TemplateName 
                                           FROM Templates 
                                          WHERE LogID = 2), '_Validated',"'")
 WHERE LogID = 2; 

Is there any possible ways to achieve this?

1 Answer 1

4

Use:

UPDATE TEMPLATES
   SET TemplateName = CONCAT("'", templatename, '_Validated')
 WHERE LogID = 2
Sign up to request clarification or add additional context in comments.

1 Comment

Thanks for your immediate reply..Sorry i have mistaken the code.. both are the same tables.. kindly saw the updated code :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.