[MAPSERVER-USERS] How to map attribute data (non-geom) from Oracle(not Spatial)?
Nolte, Tim
Tim.Nolte at ipcswirelessinc.com
Tue Aug 5 07:38:11 PDT 2008
Bill,
Here is a layer definition I am using for Oracle Spatial(Locator) data.
LAYER
GROUP "Cell Sites"
NAME "On-Air"
TYPE POINT
STATUS ON
CONNECTIONTYPE oraclespatial
CONNECTION "username/password at sid"
PROCESSING "CLOSE_CONNECTION=DEFER"
DATA "geom FROM (SELECT st.bts_nbr, sgt.geom FROM site_tab st,
site_geom_tab sgt WHERE st.site_id = sgt.site_id AND st.site_status_id
IN (4,7)) USING SRID 8307"
LABELITEM "bts_nbr"
METADATA
"static_legend" "1"
END
DUMP true
CLASS
NAME "On-Air Large Scale"
MINSCALE 0
MAXSCALE 1200000
STYLE
SYMBOL "circle"
COLOR 22 129 17
OUTLINECOLOR 255 255 255
SIZE 12
END
LABEL
TYPE TRUETYPE
FONT "sans"
SIZE 7
POSITION CR
OFFSET 0 2
ANGLE AUTO
BUFFER 3
MINDISTANCE 30
MINFEATURESIZE 10
COLOR 0 0 0
OUTLINECOLOR 245 245 231
SHADOWSIZE 3 3
BACKGROUNDSHADOWSIZE 1 -1
END
END
CLASS
NAME "On-Air Small Scale"
MINSCALE 1200000
MAXSCALE 6000000
STYLE
SYMBOL "circle"
COLOR 22 129 17
OUTLINECOLOR 255 255 255
SIZE 8
END
END
END
The key here is that you need to have MapServer compiled with Oracle
Spatial support. And you can see from my data line that that I do
standard Oracle SQL statements for building my spatial results. I'm not
using any shapefiles in this instance. The spatial data is actually
stored right in the database table. There are tools to import shapefiles
into Oracle. If your data is points you can build insert statements to
populated your geometry columns. You're probably going to want to do
some reading up on Oracle spatial.
- Tim
----
Timothy J Nolte - tnolte at ilpcs.com
Network Planning Engineer
iPCS Wireless, Inc.
4717 Broadmoor Ave, Suite G
Kentwood, MI 49512
Office: 616-656-5163
PCS: 616-706-2438
Fax: 616-554-6484
Web: www.ipcswirelessinc.com
> -----Original Message-----
> From: Bill Wordsworth [mailto:bill.wordsworth at gmail.com]
> Sent: Tuesday, August 05, 2008 10:25 AM
> To: Nolte, Tim; mapserver-users at lists.osgeo.org
> Subject: Re: [MAPSERVER-USERS] How to map attribute data
> (non-geom) from Oracle(not Spatial)?
>
> This is exciting news! I am using Oracle 10g and get Oracle Locator
> free but how do I map data from Oracle Locator? Are you doing a
> JOIN+FILTER? Can you share a LAYER snippet from your MAP file?
> Cheers, Bill
More information about the MapServer-users
mailing list