At 02:20 PM 6/22/2006, Adam Quiney wrote:
Hi all,
We're putting together an application that uses Mapserver to connect to
an ArcSDE instance running against an SQLServer back-end.
Are joins (i.e.
http://mapserver.gis.umn.edu/docs/reference/mapfile/join) supported with
ArcSDE connections? I know the ArcSDE page says "on-the-fly" joins are
not supported, but I wasn't sure if those referred to the same thing or
some other SDE-specific join?
on-the-fly joins means using the JOIN directive like is possible for
Shapefile and MyGIS drivers.
We are currently storing a set of address points in our database. We
also have a many-to-one relationship between these address points and
any number of aliases that they could hold. We would like to be able to
perform a join between each address point and all of its aliases. Is
this possible on mapserver's end, or are we limited to creating a view
in SDE that will support this?
SDE views are going to be the only way this can be done in MapServer
currently. All of the other native database drivers in MapServer
provide joins by virtual of having interfaces that behave like real
databases, rather than the database abstraction stuff that the SDE
SDK attempts to make. I haven't been able to find a need to develop
JOIN support for SDE because views were always sufficient in the
instances where I needed them.
Lastly, if this *can* be done in mapserver, is it possible to flatten
out the aliases so that the final feature that is displayed to the
browser (and that would be queried upon a get-feature-info request)
would have all of the attributes of the address point, along with an
attribute for each attached alias (the alternative being that we have
one address point/alias feature for each address point and alias pair).
Another advantage of using an SDE view is that you can control this
when creating it.
Howard