Hi Kevin, I'm assured that the 'public' part is just a default and that you CAN change the value of this keyword.
It's a Feature Type setting (not a Dataset setting) so for a mapping file you'd set it in the destination datasets' def-line parameters. The workbench equivalent would be to open the destination Feature Type settings and click the 'parameters' tab. In there you would find a setting called 'Database Schema' which you could set to whatever value you require. Your point regarding the search_path list is well taken. We've filed a PR (PR#7253) to update FME to use the search path where possible, but to default to 'public' where either the path, or the schema to which it points, don't exist. We'll let you know when this gets implemented. I hope this helps to answer your question. Regards, Mark Mark Ireland, Product Support Engineer Safe Software Inc. Surrey, BC, CANADA [EMAIL PROTECTED] http://www.safe.com Solutions for Spatial Data Translation, Distribution and Access --- In [email protected], Kevin Neufeld <[EMAIL PROTECTED]> wrote: > Does anyone know if the FME PostGIS writer can write to a schema other > than 'public' when writing to a PostGIS enabled PostgreSQL database? The > reader has a SCHEMA keyword that can fully qualify the name of the table > being read, however the writer seems to hardcode 'public' in front of > every table definition when writing to a database. > > In Postgres (verisons >7.4), a user can have a schema search_path. > Consequently, all tables created in Postgres are created in the schema > (if it exists) identified by the first parameter in the user's > search_path variable. If the current database does not have the > specified schema, the next schema in the in the search_path list is > chosen. The FME PostGIS writer does not seem to look at this variable > when writing to a database. > > > ---------------- > # sample FME script > WRITER_TYPE POSTGIS > > POSTGIS_HOST host > POSTGIS_DATASET database > POSTGIS_PORT 5432 > POSTGIS_USER_NAME user > # where the user has their search_path defined as: test_schema, public > and schema 'test_schema' exists > > POSTGIS_DEF sample_table \ > ... > > --------------- > In the log... > 2005-06-17 08:22:57| 2.1| 0.0|INFORM|Testing for the existence of > table 'public.sample_table'... > 2005-06-17 08:22:57| 2.1| 0.0|INFORM|Creating table > 'public.sample_table'... > > ---------------- > In this case, a new table should have been created in > 'test_schema.sample_table'. > > > Cheers, > Kevin > > -- > Kevin Neufeld, > Refractions Research Inc., > [EMAIL PROTECTED] > Phone: (250) 383-3022 > Fax: (250) 383-2140 Get the maximum benefit from your FME, FME Objects, or SpatialDirect via our Professional Services team. Visit www.safe.com/services for details. Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/fme/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/
