Re: [postgis-users] Publishing WMS from PostTGIS table with ARRAY type field

2011-03-19 Thread Òscar Vidal Calbet
iles[4] as file_type, > files[5] as file_size, > files[6] as file_updated > from ; > > Then join this for geoserver as you were the array table, or create a view > like the above which includes the join... > > Brent Wood > > --- On *Sun, 3/20/11, Stefan Keller * wrote: > &g

Re: [postgis-users] Publishing WMS from PostTGIS table with ARRAY type field

2011-03-19 Thread pcreso
From: Stefan Keller Subject: Re: [postgis-users] Publishing WMS from PostTGIS table with ARRAY type field To: "Òscar Vidal Calbet" Cc: "PostGIS Users Discussion" Date: Sunday, March 20, 2011, 9:16 AM Now I see. But then I would use filetype helper functions like below.

Re: [postgis-users] Publishing WMS from PostTGIS table with ARRAY type field

2011-03-19 Thread Stefan Keller
Now I see. But then I would use filetype helper functions like below. Yours, S. CREATE or REPLACE FUNCTION filetype_to_href(filetype) RETURNS text AS $$ DECLARE file alias for $1; href text := ''; BEGIN RETURN ''|| file.file_name ||''; END; $$ LANGUAGE plpgsql; -- Test: SELECT filetype_t

Re: [postgis-users] Publishing WMS from PostTGIS table with ARRAY type field

2011-03-19 Thread Òscar Vidal Calbet
Thanks Stefan. I tried already, but is happening the same. Geoserver is only publishing the fields "gid, name, description, the_geom" but no the "files". "files" is a ARRAY field with elements of a TYPE created for me. thanks, oscar 2011/3/19 Stefan Keller : > Ok. > > I think you can still turn

Re: [postgis-users] Publishing WMS from PostTGIS table with ARRAY type field

2011-03-19 Thread Stefan Keller
Ok. I think you can still turn your original view into one that is recognized by GeoServer, like this: CREATE VIEW view_my_point_feature_with_files AS SELECT gid, name, description, files, the_geom FROM my_feature, resource_file WHERE resource_file.from_table='my_point_feature'

Re: [postgis-users] Publishing WMS from PostTGIS table with ARRAY type field

2011-03-18 Thread Stefan Keller
Hi Oscar I don't understand what you really did. 1. GeoServer can only serve tables with id and geometry. 2. Can you specify the view you defined and the join? To me that would work too (except that the geometry attribute is lacking): CREATE VIEW resource_file_v(id, files) AS ( SELECT id, un

[postgis-users] Publishing WMS from PostTGIS table with ARRAY type field

2011-03-15 Thread Òscar Vidal Calbet
Hey everyone, I published some WMS services in Geoserver from PostGIS database and I need to make a GetFeaureInfo that gives me data from different tables, which can be solved by creating a VIEW. The problem is that I need that one of the fields in the VIEW be allowed to give me N entities referri