2
Good Afternoon I need to write a command inside a variable of the format varchar
Set @STRING_SQL = 'update BCS_RESOURCE set DS_DESCRICAO = ''Gestão de Contratos - ''+ @DS_PERFIL + '' , [DS_pt-BR] = ''Gestão de Contratos - '+ @DS_PERFIL + ', DS_en-EN = ''Gestão de Contratos - '''+ @DS_PERFIL + ''', DS_es-ES = ''Gestão de Contratos - '''+ @DS_PERFIL + ''' where ID_RESOURCE = '--+ CAST(@id_Resource as VARCHAR(100))
but I’m still not able to do exec this giving string concatenation error
Can you explain yourself better? I don’t understand your problem. You don’t know how to update the 3 new columns within the same update, or you are getting an error message (in this case, which)?
– lpacheco
No. I am unable to put the update command inside a varchar. example: set @Variavel_varchar = 'Update command '
– Junior Torres
still giving error Unclosed quotation mark after the Character string 'Contract Management - Requester Where ID_RESOURCE = 2003'.
– Junior Torres
You can update your question with the full code?
– lpacheco
now updated
– Junior Torres
I changed the answer
– Marco Souza