it is the first time i use this community support. if i make any mistake ´m sorry.
i hope that anybody can help me.
i try to use the PostGIS Manager Plugin 0.5.15 for QGIS 1.7.3 with the posgresql 9.1 and postgis 1.5.3 database on my MacBookPro with Mac OSX Lion 1.7.2.
Installation and connection to the PostGIS Database went everything fine.
know i want to "Load Data from Shapefile", i chose the shape file in the dalog and after i click the load button
i get the error message: "Message: Filename: None".
I have no idea what the problem is, can anybody help me?
I think the db_manager plugin superceeds the PostGIS Manager one.
Giuseppe (in Cc) is the author of db_manager, but can probably also
help with the PostGIS Manager plugin.
() Free GIS & Flash consultant/developer
I think this message should be sent to the qgis-user mailing list
as the plugin is a QGis plugin.
PostGis Manager assumes that shp2pgsql executable is in PATH
environment variable. It's unable to find it, so it throws an OSError
I'm sure that after adding shp2pgsql to the PATH env var it should
work fine, but I've no Mac so I cannot say how to do this...
I hope this helps.
thanks for the first idea to solve the problem.
i use the tool terminal and the path environment variables are:
mbp-wlan:~ fbeyerbach$ echo $PATH
i think this should work. any idea?
I've no MacOS, but few months ago I understood how it works.
Each application defines what environment variables it needs, but
the user can change them editing ~/.MacOSX/environment.plist
not the one for all the applications you run.
A way to have the same terminal's environment in an application
is to run the application from terminal.
Could you try again running Qgis from terminal?
Another solution could be to add environment variables before
PostGis Manager launches shp2pgsql, just setting PATH using
the QGis Python Console (menu Plugins):
path = os.getenv("PATH")
pgpath = "/usr/local/pgsql/share/contrib/postgis-1.5/:/usr/local/pgsql-91/bin:/usr/local/pgsql-9.1/bin"
path = pgpath if path == None or path == "" else path os.pathsp pgpath
In addition, there's a opened ticket  to add a panel to set/override
environment variables withing QGis to help OSX users.
I hope this helps.
in Mac OSX Lion there is nomore file/folder ~/.MacOSX/environment.plist
i also don´t know exactly in which file i had to add the environment variables.
in the users home directory i found the files:
these files are empty
with the command "echo $PATH" i get the following environment variables:
i found these in the file:
and under the folder
but these are really not for all applications. i hope i can find the real files where i can put in environment variables for the whole system. any idea?
here i found some tips: http://stackoverflow.com/questions/7501678/set-environment-v[..]
i followed your tipp and starteted qgis from the terminal and everything went fine with the postgis manager.
the following code in the QGis Python Console don´t solve the problem:
i think, i solved the problem. here the link to the hint:
i did the following
Open up a terminal.
defaults write ~/.MacOSX/environment PATH "/usr/local/pgsql/share/contrib/postgis-1.5:/usr/local/pgsql/bin"
thanks for the hints to solve the problem.
Could someone please add these instructions to the plugin help?
Paolo Cavallini - Faunalia
Full contact details at www.faunalia.eu/pc
I've been quietly half paying attention to this thread...
I'd rather not promote the environment.plist (or other hidden/system init file options) as *the* solution to application environment variables. Mac users shouldn't have to work with invisible files/folders to get something working. And I don't think environment.plist is well documented (*users* need to dig into the *developer* documentation to find anything).
I also found a reference that PATH set in environment.plist changed in OS X 10.6 - instead of adding to the default system paths (/usr/bin, /usr/local/bin) it completely replaces PATH for any applications (they won't see system paths unless you specify them in environment.plist).
Either plugin developers (for plugins that use command line tools) need to add program path configuration options (see the GDAL Tools plugin), or some QGIS-wide option is needed like http://hub.qgis.org/issues/3097
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com> http://www.kyngchaos.com/
All generalizations are dangerous, even this one.