I have records with entries like
\fixed\string
\fixed\string\01
\fixed\string\01\01
\fixed\string\01\01\12
\fixed\string\01\1d
\fixed\string\01\1d\30
\fixed\string\02
\fixed\string\02\23-4
\fixed\string\02\23-4\15
\fixed\string\02\23-4\15\2
now I want all all record on level 3: \fixed\string\[^\]*\[^\]*
\fixed\string\01\01
\fixed\string\01\1d
\fixed\string\02\23-4
the query was a bit complicated as mysql get confused by the backslashes and proper escaping and at last I was successful with: WHERE replace(fieldname,'\\','/') regexp '^/fixed/string/[^/]*/[^/]*$
Now I have a problem as the querybuilder in TYPO3 has no option for regular expressions.