[mapguide-users] OGR with postgis support

Traian Stanev traian.stanev at autodesk.com
Thu Aug 17 10:16:14 EDT 2006


Yes. That's what it's supposed to look like. You need to set DataSource
to point to your postgis database, for example using a string like this:

PG:dbname=postgis user=postgres password=1234567890 

And then set the ReadOnly attribute to TRUE.

Then save and hit the Test Connection button and you should get a green
check mark. If not, something is going wrong and it's failing to
connect.


Traian



-----Original Message-----
From: kenny at keniginc.com [mailto:kenny at keniginc.com] 
Sent: Thursday, August 17, 2006 10:12 AM
To: users at mapguide.osgeo.org
Subject: Re: [mapguide-users] OGR with postgis support

Guys,

I have tried to use the OGR Provider and it isn't working.

I am attaching a screenshot.  Is it supposed to look like this?

Quoting "Kenneth, GEOGRAF A/S" <ks at geograf.dk>:

> I haven't tried anything using SQL server, but I can't imagine that 
> there should any problems when connecting through ODBC.
>
> Mvh. Kenneth, GEOGRAF A/S
>
>
>
>
> kenny at keniginc.com skrev:
>> Thanks very much, Kenneth!
>>
>> I got it now.
>>
>> Just one related question. Are we still unable to connect to sql   
>> server db using ODBC?
>>
>> Quoting "Kenneth, GEOGRAF A/S" <ks at geograf.dk>:
>>
>>> There is an FDO folder for Studio in C:\Program 
>>> Files\Autodesk\MapGuideStudio2007\FDO.
>>> There is an FDO folder for MgServer in C:\Program 
>>> Files\Autodesk\MapGuideEnterprise2007\Server\Bin\FDO.
>>>
>>> Correct the above paths to your system.
>>>
>>> You must copy the OGRProvider.dll to both folders above, and edit 
>>> the providers.xml in both folders.
>>> If you use MapGuide OS, it has recently shifted to FDO 3.2, and you 
>>> have to change the version number in providers.xml.
>>> If you use MapGuide EP, you must build OGR provider, using an older 
>>> FDO snapshot, otherwise it won't load.
>>>
>>> After restarting the service and studio, you should be able to 
>>> select New -> Data connection...
>>>
>>> On the list you should now see "OSGeo FDO Provider for OGR"
>>>
>>> I hope you are working on windows, as you will have to compile a 
>>> .dll/.so for both windows and linux otherwise.
>>>
>>> Mvh. Kenneth, GEOGRAF A/S
>>>
>>>
>>>
>>> kenny at keniginc.com skrev:
>>>> Hi Kenneth and thank you for responding to this thread.
>>>>
>>>> How do you edit the providers.xml?
>>>>
>>>> It is my understanding that from the readme associated with the   
>>>> ogr  provider that I downloaded that you need to do 2 things:
>>>>
>>>> 1, add an entry, this entry:
>>>>
>>>> <FeatureProvider>
>>>>   <Name>OSGeo.OGR.0.1</Name>
>>>>   <DisplayName>FDO Provider for OGR</DisplayName>
>>>>   <Description>Access to OGR data sources</Description>
>>>>   <IsManaged>False</IsManaged>
>>>>   <Version>0.1.0.0</Version>
>>>>   <FeatureDataObjectsVersion>3.1.0.0</FeatureDataObjectsVersion>
>>>>   <LibraryPath>OGRProvider.dll</LibraryPath>
>>>>  </FeatureProvider>
>>>>
>>>> to providers.xml and as you correctly stated, add the   
>>>> OGRprover.dll  into FDO.
>>>>
>>>> I have done these and restarted the mapGuide service.
>>>>
>>>> If all goes well, when you go to Studio and attempt to add a    
>>>> database connection, you should the OGR provider. Right now, I   
>>>> only  see the ODBC connection that I set up awhile back.
>>>>
>>>> Did I miss something?
>>>>
>>>> Quoting "Kenneth, GEOGRAF A/S" <ks at geograf.dk>:
>>>>
>>>>> You must edit providers.xml and copy the dll into the FDO
directory.
>>>>> This must be done in both the Service FDO folder and the Studio   
>>>>> FDO folder.
>>>>>
>>>>> I'm guessing that Studio uses the GUI part, and the Service does 
>>>>> the actual data access.
>>>>>
>>>>> Perhaps Studio should be modified to load this from the server?
>>>>> But then there would be windows/linux problems.
>>>>>
>>>>> I don't know how this works in Web Studio, if thats what you are
trying.
>>>>>
>>>>> Mvh. Kenneth, GEOGRAF A/S
>>>>>
>>>>>
>>>>>
>>>>> kenny at keniginc.com skrev:
>>>>>> Ok,
>>>>>>
>>>>>> I know I have been a bit slower catching on to this than most,   
>>>>>>   largely because other extreme commitments but please bear with

>>>>>> me.
>>>>>>
>>>>>> I just downloaded, unzipped and compiled OGR Provider with    
>>>>>> PostGIS  support so I can gain direct access to some of our   
>>>>>> files  using  connections.
>>>>>>
>>>>>> After adding an entry to providers.xml, I restarted service,   
>>>>>> wen  to  studio and database connection but it isn't there.
>>>>>>
>>>>>> What am I doing wrong?
>>>>>>
>>>>>> Thanks very much in advance
>>>>>>
>>>>>> -----------------------------------------------------------------
>>>>>> ---- To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
>>>>>> For additional commands, e-mail: users-help at mapguide.osgeo.org
>>>>>>
>>>>>
>>>>> ------------------------------------------------------------------
>>>>> --- To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
>>>>> For additional commands, e-mail: users-help at mapguide.osgeo.org
>>>>
>>>>
>>>>
>>>> -------------------------------------------------------------------
>>>> -- To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
>>>> For additional commands, e-mail: users-help at mapguide.osgeo.org
>>>>
>>>
>>> --------------------------------------------------------------------
>>> - To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
>>> For additional commands, e-mail: users-help at mapguide.osgeo.org
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
>> For additional commands, e-mail: users-help at mapguide.osgeo.org
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
> For additional commands, e-mail: users-help at mapguide.osgeo.org








More information about the Mapguide-users mailing list