Alaska Geologic Materials Inventory KML Programming Guide
Authors: Johnson, K.J., Riordan J.A., Papp K.R., and Johnson, K.A.
This explanation briefly outlines and shows examples of how the Alaska Geologic Materials Center (GMC) uses Keyhole Markup Language (KML) programming to publish parts of our geologic materials inventory. The GMC currently uses Microsoft Access to store it's inventory information, but the process is essentially the same from any SQL database such as Oracle or MySQL. The GMC runs two parallel systems for Oil & Gas and Hardrock Minerals. The text below only illustrates examples using the Oil & Gas code. Full documentation of the Visual Basic code are in the formal metadata.
The general usability and work-flow of this system is outlined below. This system creates thousands of static files that must be updated when significant changes to the inventory occur. A more dynamic or real-time generation of inventory code would be desirable, but are not possible from our Access Database system. The GMC is currently working with staff at the Division of Geological and Geophysical Surveys (DGGS) to migrate its inventory information into the DGGS Oracle database.
The User downloads a KML control file to access the Alaska Geologic Materials Inventory from a program such as Google Earth.
This KML control file links to two geolocation KML files (or layers) for both Oil and Gas or Minerals map locations and summary level inventory located on a web server.
Each Oil and Gas or Minerals KML file provides a link to a detailed inventory for a given well or borehole displayed in separate HTML files on a web server.
All the KML and HTML files on the server can be updated without affecting the user as a result of using the Network Link element provided in the KML specification. The KML control file that the user loads into Google Earth, for example, generally remains unchanged.
This project required some knowledge of SQL queries, Microsoft Visual Basic, the KML language, and the HTML language. The four major project steps follow below.
GMC Inventory Code Examples
Design SQL queries to generate the geologic oil and gas well material inventory information.
Our first query pulls up the following information: Wellname, Latitude, Longitude, API_snippet, PermitNo_snippet, Operator_snippet, TotalDepth_snippet, Basin_snippet, CompletetionDate__snippet, and API. This information is mostly obtained by the well header from the Alaska Oil and Gas Conservation Commission.
The actual SQL code is a bit more complicated but finds the data listed above: Example
Wrap the appropriate queries in Visual Basic code to create KML text files with well locations, summary data, and links to HTML well details files.
Wrap the appropriate queries in Visual Basic code to create HTML text files with well inventory details.
Publish the resulting KML and HTML files to a web server and create a small static public KML file to run the GMC Inventory system: Example
Please contact Kurt Johnson should you have additional questions.