<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Hi Carl.<br>
<br>
Thank you for finding this problem.<br>
There were another problem with the multiple schemas, namely that all
tables would be assigned to the very first schema.<br>
I have included you fix, the fix for multiple schemas, and the fix for
the unmapped datatypes in r3392.<br>
On my simple test setup, I can now use MsSql Spatial data, let me know
if it works for you too.<br>
<pre class="moz-signature" cols="72">Regards, Kenneth Skovhede, GEOGRAF A/S
</pre>
<br>
<br>
Carl skrev:
<blockquote cite="mid:20015751.post@talk.nabble.com" type="cite">
  <pre wrap="">Exactly, the returned XML based on the new version of SQLSpatialProvider
covers all tables.
But now the root node name is changed to 'fdo:DataStore', and Maestro check
that the root node name must be 'xs:schema'.  (as follows)

///////////////////////////////////
public class FeatureSourceDescription
        {
                private FeatureSourceSchema[] m_schemas;

                public FeatureSourceDescription(System.IO.Stream stream)
                {
                        XmlDocument doc = new XmlDocument();
                        doc.Load(stream);

                        if (doc.FirstChild.Name != "xml")
                                throw new Exception("Bad document");

                        if (doc.ChildNodes.Count != 2 || doc.ChildNodes[1].Name != "xs:schema")
                                throw new Exception("Bad document");

                        XmlNamespaceManager mgr = new XmlNamespaceManager(doc.NameTable);
                        mgr.AddNamespace("xs", <a class="moz-txt-link-rfc2396E" href="http://www.w3.org/2001/XMLSchema">"http://www.w3.org/2001/XMLSchema"</a>);
                        mgr.AddNamespace("gml", <a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/gml">"http://www.opengis.net/gml"</a>);
                        mgr.AddNamespace("fdo", <a class="moz-txt-link-rfc2396E" href="http://fdo.osgeo.org/schemas">"http://fdo.osgeo.org/schemas"</a>);

            XmlNodeList lst =
doc.SelectNodes("xs:schema/xs:complexType[@abstract='false']", mgr);
                        m_schemas = new FeatureSourceSchema[lst.Count];
                        for(int i = 0;i&lt;lst.Count;i++)
                                m_schemas[i] = new FeatureSourceSchema(lst[i], doc, mgr);
                }
......

///////////////////

Then I changed the Maestro to fit the new version
1. Check the root node name : 'fdo:DataStore'
2. Modify the line
XmlNodeList lst =
doc.SelectNodes("xs:schema/xs:complexType[@abstract='false']", mgr);

as 

XmlNodeList lst =
doc.SelectNodes("fdo:DataStore/xs:schema/xs:complexType[@abstract='false']",
mgr);

OK. It works well. all tables are listed, and the table containing a
geometry field is shown as default.


Brent Robinson-5 wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">One clarification. The fix is specific to the handling of varchar(max) and
nvarchar(max). It likely doesn't address the problem mentioned at
<a class="moz-txt-link-freetext" href="http://www.nabble.com/Maestro%3A-can%27t-find-the-table-containing-the-geometry-field-with-SQLServerSpatial-tp19977173p19994687.html">http://www.nabble.com/Maestro%3A-can%27t-find-the-table-containing-the-geometry-field-with-SQLServerSpatial-tp19977173p19994687.html</a>

-----Original Message-----
From: <a class="moz-txt-link-abbreviated" href="mailto:mapguide-users-bounces@lists.osgeo.org">mapguide-users-bounces@lists.osgeo.org</a>
[<a class="moz-txt-link-freetext" href="mailto:mapguide-users-bounces@lists.osgeo.org">mailto:mapguide-users-bounces@lists.osgeo.org</a>] On Behalf Of Brent
Robinson
Sent: Wednesday, October 15, 2008 12:37 PM
To: MapGuide Users Mail List
Subject: RE: [mapguide-users] Maestro: can't find the table containing the
geometry field with SQLServerSpatial

This is a known defect that was fixed in July. The fix provides almost
full support for the varchar(max) and nvarchar(max) columns. There's one
limitation: when selecting from these columns, values longer than 16000
characters are truncated.

The FDO 3.3.2 SQLServerSpatial provider should have the fix. It can be
obtained from the Windows SDK download at
<a class="moz-txt-link-freetext" href="http://fdo.osgeo.org/content/fdo-332-downloads">http://fdo.osgeo.org/content/fdo-332-downloads</a>. You'd just need to extract
the following DLL's:

        SQLServerSpatialProvider.dll
        SQLServerSpatialOverrides.dll
        OSGeo.FDO.Providers.SQLServerSpatial.Overrides.dll

to MapGuide's FDO bin directories:

        Program Files\Autodesk\MapGuideEnterprise2009\Server\Bin\FDO
        Program Files\Autodesk\MapGuideStudio2009\FDO  (if present)

I'd recommend saving copies of your current versions of these DLL's before
extracting, just in case.

I have MG enterprise on my machine so your directories might look a bit
different.

If you get a chance to try this out, please let me know if it fixes the
problem.


-----Original Message-----
From: <a class="moz-txt-link-abbreviated" href="mailto:mapguide-users-bounces@lists.osgeo.org">mapguide-users-bounces@lists.osgeo.org</a>
[<a class="moz-txt-link-freetext" href="mailto:mapguide-users-bounces@lists.osgeo.org">mailto:mapguide-users-bounces@lists.osgeo.org</a>] On Behalf Of Carl
Sent: Wednesday, October 15, 2008 10:28 AM
To: <a class="moz-txt-link-abbreviated" href="mailto:mapguide-users@lists.osgeo.org">mapguide-users@lists.osgeo.org</a>
Subject: RE: [mapguide-users] Maestro: can't find the table containing the
geometry field with SQLServerSpatial


yes


Brent Robinson-5 wrote:
    </pre>
    <blockquote type="cite">
      <pre wrap="">Hi Carl,

Do any of your tables have a varchar(max) column?

Brent.



      </pre>
    </blockquote>
    <pre wrap="">--
View this message in context:
<a class="moz-txt-link-freetext" href="http://www.nabble.com/Maestro%3A-can%27t-find-the-table-containing-the-geometry-field-with-SQLServerSpatial-tp19977173p19994687.html">http://www.nabble.com/Maestro%3A-can%27t-find-the-table-containing-the-geometry-field-with-SQLServerSpatial-tp19977173p19994687.html</a>
Sent from the MapGuide Users mailing list archive at Nabble.com.

_______________________________________________
mapguide-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:mapguide-users@lists.osgeo.org">mapguide-users@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/mapguide-users">http://lists.osgeo.org/mailman/listinfo/mapguide-users</a>
_______________________________________________
mapguide-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:mapguide-users@lists.osgeo.org">mapguide-users@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/mapguide-users">http://lists.osgeo.org/mailman/listinfo/mapguide-users</a>
_______________________________________________
mapguide-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:mapguide-users@lists.osgeo.org">mapguide-users@lists.osgeo.org</a>
<a class="moz-txt-link-freetext" href="http://lists.osgeo.org/mailman/listinfo/mapguide-users">http://lists.osgeo.org/mailman/listinfo/mapguide-users</a>


    </pre>
  </blockquote>
  <pre wrap=""><!---->
  </pre>
</blockquote>
</body>
</html>