I need to extarct all links from a database so I can create a URL rewrite. Using a SQL statement, how can I extract just links from a table? Sometimes there is more than one link within a cell which further complicates it. Any idea on how to achieve this?
EDIT
An example of this would be: SELECT myval FROM htmlcontrols.
"myval" has an HTML string such as "<div>Hi this is a test. <a href="somewhere.htm">Click here</a> or <a href="http://somewhereelse.com/testarea">here</a></div>
". I want an extract like this:
LINKS
-----
somewhere.htm
http://somewhereelse.com/testarea