1

Re: Purpose of OBJECT_ID in LOCATION_BOUNDARY table

Hello,
I am trying to get my head around how to link spatial features from a GIS layer to Locations in Recorder.  If I have a drainage layer in which specfic drains relate to Survey_event locations and I import the layer into Recorder, I can manually associate a specific drain to a location but is there anything in the underlying tables that can pick up a reference identifier of the specific feature and associate it to a record in the Location table.  I thought that the OBJECT_ID field in the LOCATION_BOUNDARY table would do this but I am told that this field is populated on the fly each time a layer is imported so does not use any existing identifiers from the original layer. 

Is this an issue for anyone else?

Thanks,
Anne

2

Re: Purpose of OBJECT_ID in LOCATION_BOUNDARY table

It is an issue for all who wish to use GIS with Recorder. There is no specific field for external GIS polygon identifiers in the Recorder data madel. This an unacceptable situation since the utility in Recorder is not claimed to be a GIS but simply a "mapping tool" (Hannah Betts' quote). This will be one of the issues raised at the NBN's Data Tools and Standards Steering Group this Friday (2nd March).
If you want any kind of connection the only field available is "File Code" (described in the data model as "File code for location. Not Required") on the Location's "General" tab. We use this for all our Local Wildlife Sites etc. because there is nothing else. It won't display a full 16 characters (although the field is 20 varchars) and so we have to truncate our "NBN standard" 16 digit code adopted for our polygon IDs and then pad them out again later.  A live connection is out of the question at the moment but a real GIS polygon ID field would be a good start.

3

Re: Purpose of OBJECT_ID in LOCATION_BOUNDARY table

You could try a query which joins LOCATION_BOUNDARY to LOCATION (via the LOCATION_KEY). LOCATION has lat/lon which you could use for a spatial reference to the GIS.

Depending on your GIS, one could use ODBC to expose the Recorder database to the GIS and then create the query in the GIS.

Otherwise the query could be done externally to Recorder to export out a data file for import to the GIS. Granted this is not a live link, but depending on the frequency your data changes, may not be an issue.

Cheers,

Dave Cope,
Biodiversity Technology Officer,
Biodiversity Information Service for Powys and Brecon Beacons National Park.

4

Re: Purpose of OBJECT_ID in LOCATION_BOUNDARY table

I have only just started working on this problem, in particular I have only just begun to think about it in the context of Rec 6.

With that understood however, I have a half-finished visual basic module, which I hope I will eventually be able to wrap as a com object as addin to Recorder, which will essentially be a copy of mapinfo with direct access to the database (at the moment it accesses another SQL database).

It seems to me though that the LOCATION_BOUNDARY table is a bit of a distraction in this context. The location is identified uniquely in the LOCATION table in Recorder (or whatever it's called - I really am that much of a beginner!) , so put that ID in your GIS layer & you have the link.

I realise however that by doing this you will be bypassing the functionality of the Recorder map window, and I should say at this point that I envisage my addin as being effectively a replacement for the map window, but with full GIS functionality.

It is very early days for me and recorder, and I don't in any way underestimate the size of the task I have set myself, but watch this space, by next spring I hope to have more to say.

If anyone can point me in the direction of useful resources relating to Recorder COM addins and also to the way in which Recorder stores and handles the map window data I would be really grateful.

Rob Large
Wildlife Sites Officer
Wiltshire & Swindon Biological Records Centre

5 (edited by johnvanbreda 24-07-2008 10:00:59)

Re: Purpose of OBJECT_ID in LOCATION_BOUNDARY table

Hi Rob

The COM addin documentation is available here:
http://forums.nbn.org.uk/uploads.php?fi … corder.zip

The Recorder map component uses a product called MapServer 5 Turbo (http://www.graticule.com/), not to be confused with the open source MapServer web library. The file formats (*.gsf) it uses are proprietary to that product and I don't know if they are documented anywhere. If you really need to access the content you might need to purchase a developer license from Graticule to access their dlls directly, but I suspect you won't need to.

In theory at least, what you are proposing should work. You need to write an ActiveX class that implements IRecorderAddin (see the documentation) and probably INewAction to get it to appear on a menu. Then place MapInfo on your ActiveX. You should be able to implement drag and drop to receive things dropped from Recorder such as taxa from the dictionary then run your own queries to pick up all the records. The drag and drop format is described in the above document. To get data from the Report Results window to your GIS it might be easiest to save it as a SHP file then open that file from your addin.

You should be able to get Recorder's type library by importing it from the RecorderApp.exe file but if not I will check with JNCC if it's OK to supply you with the latest tlb file.

The Location_Boundary table may not be required in your case as it is used to link to MapServer 5 Turbo.

Good luck, I'd be interested to see how you get on!

John van Breda
Biodiverse IT

6

Re: Purpose of OBJECT_ID in LOCATION_BOUNDARY table

Thanks John, that looks like just what I needed. I will of course keep you informed and will probably be asking a lot more questions by and by.

Rob Large
Wildlife Sites Officer
Wiltshire & Swindon Biological Records Centre