O'Reilly logo

Learning Oracle PL/SQL by Steven Feuerstein, Bill Pribyl

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

8.4. Fetching Data from a Remote Web Site

With so much information available on public web sites, sooner or later you will probably want to fetch and save some of it into your local database. If at all possible, a library would prefer to import catalog information electronically from an external source such as the publisher, or from another library's catalog, rather than keying it by hand. As it turns out, this is not a very original idea.

Data retrieval from real library catalogs is an enormous and complex topic, rich with multiple standards, proprietary products, open source tools, and plenty of controversies. I don't pretend to know anything about it. I have contrived an example merely to show off some aspects of PL/SQL that could be useful in many applications.

But even if we can find the data we need, will it require a rocket scientist to pull it down into our local database? The answer is, it depends—primarily, it depends on how well the creators of the remote web site have organized the data. An orderly presentation shouldn't be too challenging, even for a beginning programmer.

Assuming at least a semi-organized web site, can we meet this data-fetching challenge with PL/SQL? Probably. Again, we will turn to Oracle's built-in features, and explore how to use several more of Oracle's own packages.

8.4.1. Fetching Book Catalog Information from the Library of Congress ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required