Oracle 10g and RSS feeds
Is feeding a db in Oracle 10gR2 from an rss feed possible? If so how do I start with this? If not, do I have to use an intermediary (i.e. Java or something)?
开发者_如何转开发The premise:
I am trying to develop an earthquake event database based on feeds from earthquakes.usgs.gov. Using their feed I would be able to maintain a near real time db of events. I ask about this route (RSS) because I don't want to use their software (it's limited in function) and I don't think the boys at caltech will allow me a connection to their DB to pull everything relevant.
any suggestions would be great, links to relevant information sources would be better, examples would be awesome.
Thanks in advance.
Absolutely - and you can do it in PL/SQL.
You could use UTL_HTTP to grab the raw feed and parse it yourself; or you can use dbms_xmlparser as demonstrated in this article:
http://technology.amis.nl/blog/1173/building-an-rss-feed-reader-in-plsql-using-utl_http-dbms_xmldom-and-dbms_xslprocessor-for-parsing-and-transforming
Even better - you can just take someone else's example and customise it to your requirements: http://ora-00001.blogspot.com/2011/02/fun-with-rss-and-plsql-part-one.html
精彩评论