0

I know the concept of schemas from XML and databases, and I hope it has the same meaning in GIS.

I have to record some data about street light and hand it over to the municipality as a Shapefile. They specified that they want a zipped folder containing a Shapefile, and they specified a number of attributes that are required. However the attributes were given to me as a list in human readable language. Here are a few examples from the list:

  • Lamp type
  • Height
  • Power
  • Night energy saving

However, they did not specify the name of the attributes within the database. If I understand correctly, an attribute name can be no longer than ten characters so someone would have to decide what to call ´night energy saving´ in ten characters. Furthermore, they did not specify a datatype (including length/precision) for any of them.

I will do the best I can with what I was told, but this situation made me wonder.

How does someone specify the format/schema in which they want data.

Is there a kind of file that defines the format/schema?

If I understand correctly the format/schema is self contained within the Shapefile, so perhaps the correct approach is to distribute an empty Shapefile?

And how does one verify if a Shapefile is valid according to a schema?

2
  • You can't really do that, best to use a better format
    – Ian Turton
    Commented Sep 23, 2021 at 18:26
  • You can't create another file that defines the structure of a shapefile. You can document what the fields mean in the metadata which you should always do with any spatial dataset. This is an XML file that follows the dataset around with the gis system. So for example you could describe what "power" is, it's limitations, units etc. If you are using Arcmap then this is what arccatalog was designed for.
    – Hornbydd
    Commented Sep 25, 2021 at 10:09

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.