I have a variable in my database function:
@LocalVariable = \'2*3*100\'
I want to get the result by executing the expression in another var
I got a better solution, I though of sharing with you all
DECLARE @x xml DECLARE @v FLOAT SET @x = '' SET @v = @x.value('(1 + 4) div 3', 'FLOAT') SELECT @v
This will work in function too.