KML import


What is it?

KML is an XML-based file format for describing geographic objects, used in particular by Google Earth and Google Maps. Heurist has some support for importing KML files - this is currently the only practical method for adding large amounts of geographic data to the system.

How do I use it?

Select "Import records" from the "Tools" menu on the Heurist search page. Select a KML file to import; Heurist will recognise the format and process the file, and prompt you for a record type. All records created by a single KML import will have the same record type.

Heurist attempts to import each <Placemark> as a separate record. The following table lists the KML tags that Heurist recognises as record details, and the bibliographic data fields that they are imported to.

KML tag Heurist detail field
<name>
Title (detail type #160)
<address>
<AddressDetails>
Location (#181)
<phoneNumber>
Contact information (#309)
<TimeSpan><begin>
Start Date (#177)
<TimeSpan><end>
End Date (#178)
<TimeStamp><when>
Date (#166)
<Region>
<Point>
<LineString>
<LinearRing>
<Polygon>
<MultiGeometry>
Geographic object (#230)
<Snippet>
<description>
<Metadata>
Public scratchpad

It is possible to specify Heurist-formatted data in HXTBL format between KML's <Metadata> tags, e.g.

      ...
       <Placemark>
       ...
        <Metadata>

         <detail name="Name of organisation" id="160">
          Archaeological Computing Laboratory
         </detail>

         <detail name="Organisation type" id="203">
          Laboratory
         </detail>

        </Metadata>
       ...
       </Placemark>
      ...
Heurist will add fields of type #160 (Title) and type #203 (Organisation type) to the record corresponding to this <Placemark>.

Updating existing records

If you specify an existing record ID in the ExtendedData element, the importer will update that record as follows:

For example,

<ExtendedData><Data name="HeuristID"><value>1234</value>

How do I create KML?

KML is natively exported by Google Earth. Other applications can export data in KML format using a plugin, including ArcGIS and CartoWeb. The format is documented online so it is possible to "hand roll" your own KML by hand, using an XML editor.