Limitations of Web Queries
Web queries are great for the ad hoc import of data onto a worksheet, but they rely on the position of elements on the page. If the structure of the source web page changes, the query may break. This means that web queries aren’t well-suited for deployed solutions, since you are likely to get a great number of support calls if the source web page changes or moves.
Also, you’ve got to compose complicated site-specific Connection properties (query strings) if you want to perform customized queries. The YahooDates helper function shown earlier is a good example of the type of work you have to do to get a web query to work correctly with variable data such as variable date ranges. Each web site has its own system of sending and receiving data through query strings and it can be difficult to reverse-engineer those query strings correctly.
These limitations are not present when using web services—that technique provides both a stable platform and a well-defined programming interface. However, web services are not available for all data on the Internet so, in many, many cases, web queries are still very useful.
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access