Hannu Krosing <[EMAIL PROTECTED]> writes: > I guess our regex implementation already uses boyer-moore or similar. > Why not just expose the match position of substring('text' in 'regex') > using some function, called match_position(int searched_text, int > regex, int matchnum) ?
If it did that might be a nice solution, but I'm not sure that it does use B-M ... I can't find either "Boyer" or "Moore" in its source code. There's no particular reason to suppose offhand that a regex engine would be faster than the naive code for fixed patterns. regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match