I am trying to write a sentence that gets only the strings which are just before a certain character.
DECLARE @TEST VARCHAR(MAX) SET @TEST = 'CAMP1 = 4 AND CAMP2 = 5 OR CAMP3 = 7 AND CAMP4 = 9'
I am trying to to parse the string
@TEST and get only the camps one by one and check if this camps (CAMP1, CAMP2, CAMP3, CAMP4) realy exist.
I don't know if loop would be necessary to sweep the string and get the strings before '=' and after the logic operators 'AND, OR'.
Any help pls ?