QueryByPoint and MySQL
Fawcett, David
David.Fawcett at STATE.MN.US
Tue Feb 5 05:49:46 PST 2008
Jill,
I am guessing that you will need to add the names of your attribute
columns to the select statement in your connection string.
David.
-----Original Message-----
From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On
Behalf Of Jill Recla
Sent: Monday, February 04, 2008 5:41 PM
To: MAPSERVER-USERS at LISTS.UMN.EDU
Subject: [UMN_MAPSERVER-USERS] QueryByPoint and MySQL
Hi all,
I'm trying to modify the 5.x Itasca demo (itasca_adds_dhtml) to create
layers from a MySQL database. The layers are created successfully, but
when I select "Query Feature" and click a MySQL data layer point, I get
this error:
Content-type: text/html msOGRFileGetItems(): OGR error. Layer
MYSQL:genosis,user=root,password=Passw0rd,port=3306,tables=gene_data,-1
contains no fields.
Here is the layer definition in my .map file:
LAYER
NAME lines
TYPE LINE
STATUS OFF
CLASS
NAME 'lines'
STYLE
COLOR 150 0 0
SYMBOL 'circle'
SIZE 5
END
END
TEMPLATE "templates/lines.html"
CONNECTIONTYPE OGR
CONNECTION
"MYSQL:genosis,user=root,password=Passw0rd,port=3306,tables=line_data"
DATA "SELECT line FROM line_data"
END
I have made the line.html template file with the corresponding MySQL
fields. I know I'm missing something simple, here........ Can someone
please help?
Thanks,
Jill
--
*****************************************************
*****Jill M. Recla****UMaine Functional Genomics*****
***jill.recla at jax.org*****************906-282-8033***
*****************************************************
More information about the MapServer-users
mailing list