Using JOIN for querying
David.Fawcett at STATE.MN.US
Wed Sep 6 10:01:29 EDT 2006
To me, the query is returning what I would expect from a database query.
Formatting the results as you want them seems more like a templating or
data formatting issue, not a query issue.
format the results the way that you want.
Does anyone who has done more with MapServer templates know how/if this
could be done with template magic?
From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On
Behalf Of Greg Luker
Sent: Sunday, September 03, 2006 6:49 PM
To: MAPSERVER-USERS at LISTS.UMN.EDU
Subject: Re: [UMN_MAPSERVER-USERS] Using JOIN for querying
(sorry for the long post)
David Fawcett said:
>I haven't been following this thread too closely, but are you sure that
>you want to use the unmaintained MyGIS option, or do you really want to
>use OGR with MySQL support enabled? I would go with OGR unless there
>is something in MyGIS that doesn't exist in OGR.
Thanks for your suggestions. I agree that I would be better off with OGR
- and I have:
FROM site s
JOIN feature f ON s.site_id = f.feature_site_id
<GeometryField encoding="PointFromColumns" x="site_easting_other"
NAME "Test Site - pts"
COLOR 0 0 255
Using a map mode of nquery, the template pquery.html produces:
Site Name Feature
but what I want is:
I can't seem to get this using OGR (I don't know the correct syntax) so
I thought I'd try to get what I wanted by using MyGIS because somebody
helped me with the syntax.
>Here is Frank's page for OGR/MySQL:
>Here is a description from Howard's blog:
Thankyou for these URLs. I have been to them both and, while they are
helpful, I still don't know the right OGR syntax for what I'm trying to
do. Could you help with the correct OGR syntax?
>Also, look at the HowTos, there are a few items on MySQL.
Could you please give a URL for these HowTos? I have Google-searched and
asked on this list for weeks, but unfortunately I have not solved my
"OGR/MySQL/query/multiple tables/join" question, though I have received
related help from several on this list (thanks).
More information about the mapserver-users