Ravi Dangeti wrote:
Hi,

I am trying to implement a database key word search for mysql database. Its functionality could be like that of mysql "match" function. I am not sure if the pattern matching supports all the options of "match" function.
Any information regarding this?

Thanks and Regards
Ravi Shankar

Hi Ravi,

The most powerful form of string matching that Links supports in the SQL queries it generates is the "like" keyword, which matches using wildcards:

name like 'ravi%' -- matches 'ravi dangeti' and 'ravi shankar'
name like 'ravi' -- matches 'ravi' but not 'ravi dangeti'
name like '%x%y%z%' -- matches 'abxcdeyfghz'

In Links, you can use arbitrary regular expressions. If the regex can't be converted to a wildcard match like this, then all the rows are selected and then filter by the Links runtime.

Hope that helps,
Ezra



--
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.

_______________________________________________
links-users mailing list
[email protected]
http://lists.inf.ed.ac.uk/mailman/listinfo/links-users

Reply via email to