I have a table called answer
that is filled with answers to certain questions, each answer usually starts with the letter that would be the answer, for example: a)..., b)..., c)... ou d)...,
The problem is that it does not always start like this, with a html
code to return the response letter, it can be <p>a)...
I would like a query that returns only the letter that comes before the parenthesis )
, also remembering that it should only take the value that precedes the first parenthesis, if other parentheses may appear in the answer.
I'm using it like this:
Select substr(answer,1,1) AS resposta
But it will not do if something else comes before the response letter.