If you are a real nerd like me, you may think you've lucked out if you have a secure and workable way to connect your Drupal site directly to an ILS's own SQL database. You'll be able to grab any and all the data you want, relatively efficiently using the methodology and protocol you're probably already very familiar with. But don't get too excited about this option. While it's good for grabbing that known set of IDs I discussed above, you don't really want to have to learn and figure out some new and esoteric schema. I mean, it's about as good an idea as writing your own SQL queries against a Drupal database with no knowledge of the application (good luck). And of course, there's no way you would think about actually trying to write to ILS's database. Make sure you exhaust all the other options before resorting to this.