Hi,
I want to let users to input regular expressions to search in a data table. If someone input an invalid regexp such as:
abc[1
the site will crash because
select * from table where attribute ~* $value
is not a valid query.
I want to validate the input before processing, I have tried
if {[info complete "regexp $value {}"]} {
show error page
}
This deals with input such as:
abc[1
However the site still crash with:
abc[]
is there any other TCL command that I can use do to validate a regular expression?
Thanks a lot
Paul