scousethemoose
Programmer
Hi everyone,
Hopefully someone may be able to help me with this. I'm trying to write a function that will take the following boolean string and convert it to the SQL equivalent.
eg: "Indie OR Soul AND Metal AND Punk AND NOT HipHop"
I am using full text indexing and need to match across columns.
So my query would look like this:
Does anyone know of an example I could look at? I have a feeling I'm going to have to brush up on regular expressions.
Any help would be greatly appreciated, thanks.
Hopefully someone may be able to help me with this. I'm trying to write a function that will take the following boolean string and convert it to the SQL equivalent.
eg: "Indie OR Soul AND Metal AND Punk AND NOT HipHop"
I am using full text indexing and need to match across columns.
So my query would look like this:
Code:
SELECT id FROM table WHERE activated = 1 AND Contains((column1,column2),"Indie") OR Contains((column1,column2),"Soul") AND Contains((column1,column2),"Metal") AND Contains((column1,column2),"punk") AND NOT Contains(column1,column2,"HipHop")
Does anyone know of an example I could look at? I have a feeling I'm going to have to brush up on regular expressions.
Any help would be greatly appreciated, thanks.