[postgis-users] CityGML in PostGIS - 3D City Database released

Felix Kunde felix-kunde at gmx.de
Sun Dec 16 09:55:45 PST 2012


Hi Babou

FIRST: change to PostGIS 2.0!! From the screenshots I can see that you've created a PostGIS database. Good, but still not applicable for the 3D City Database. You will run into errors when executing the SQL scripts.

Concerning your questions:

1) .Sh is only for UNIX etc. You don't have to work with a shell environment (for chmod etc.) when using the .bat-files.

2) You have to edit the batchfile with a text editor! Use your connection parameters, like:

PGPORT=5432
PGHOST=localhost
PGUSER=postgres
CITYDB=citydb
PGBIN=C:\Program Files\PostgreSQL\8.4\bin 
(that's enough as PGBIN is concatenated with '\psql.exe' later in the file)

Then you can execute it the file by double clicking. You will be asked for your password and you have to enter your spatial reference system.

3) Not necessary when working with the batchfile.

4) That's true. The batchfile is calling CREATE_DB.sql (which calls CREATE_GEODB_PKG.sql) so that you don't need to work with the shell environment too much. The bat-files are just a little help. Otherwise you can call CREATE_DB.sql by using psql from command line. But first try out the bat-files with the right parameters. As I said, if you are facing more errors this is probably due to your PostGIS version, that is too low.

Best regards
Felix





-------- Original-Nachricht --------
> Datum: Sun, 16 Dec 2012 08:05:25 -0800 (PST)
> Von: babou <hiba.maalaoui at gmail.com>
> An: postgis-users at postgis.refractions.net
> Betreff: Re: [postgis-users] CityGML in PostGIS - 3D City Database released

> hi
> I followed the tutorial, but I have not accomplished the desired result
> :(, I
> made screenshot,  can you specify me my mistakes please.
> I have some questions
> 1) in the tutorial, "A more" comfortable way is CREATE_DB.bat Offered
> with shell
> scripts for Microsoft Windows family or CREATE_DB.sh for UNIX / Linux and
> derivates as well as MacOS X " so I understand that .Sh file only for unix
> /
> Linux OS?
> but after you talked about. sh (The. sh scripts can be run from Within a
> shell environment) in my case (I use windows OS) so I am interested only
> by
> .bat file? and I never use .sh file. so I have to "chmd u + x" and ". /
> CREATE__DB.sh" for CREATE__DB.bat?
> 
> 2) "The Windows batchfiles are then Executed by double-clicking". when I
> click on .bat file it displays a list of commands and when I press a key
> it
> closes? so I repeated this step twice?
> 3) " 3dcitydb/postgis "subfolder Within the installation directory of
> the Import
> / Export." is what I Work with the file. bat where the location is
> "C: \ Program Files \ Import-Export-3DCityDB \ 3dcitydb \ postgis \
> CREATE_DB.bat"
> 4) you do not talk about CREATE_DB.sql and CREATE_GEODB_PKG.sql?
> 
> thank you for any help:)
> 
> 2012/12/12 Felix Kunde [via PostGIS]
> <ml-node+s17n5002029h72 at n6.nabble.com>
> 
> > Hi Babou
> >
> > I'm happy to hear that you're starting tests with the 3D City Database
> in
> > PostGIS. I've thought my little tutorial was easy to understand. But let
> me
> > help you out.
> >
> > First of all: PostGIS version 2.0 is mandatory for the 3D City Database.
> > It will not work with PostGIS 1.4! PostgreSQL 8.4 is ok.
> >
> > From your screenshot I can see that the database you have created
> > ('citydb') has no PostGIS elements inside. No functions etc. Create a
> new
> > database using a PostGIS 2.0 template (template_postgis_20 or postgis20)
> or
> > add the PostGIS extensions.
> >
> > Then you have to set up the database with a script. This is explained in
> > detail in the tutorial (Step 4 on page 14). You can edit and execute the
> > batchfile CREATE_DB.bat to make it a bit easier. The script will create
> all
> > tables and also the additional schema 'geodb_pkg'. Only then you will be
> > able to connect to your 3D City Database with the Importer/Exporter
> tool.
> >
> > Any further questions?
> >
> > cheers
> > Felix
> >
> > -------- Original-Nachricht --------
> > > Datum: Wed, 12 Dec 2012 06:24:13 -0800 (PST)
> > > Von: babou <[hidden
> email]<http://user/SendEmail.jtp?type=node&node=5002029&i=0>>
> >
> > > An: [hidden
> email]<http://user/SendEmail.jtp?type=node&node=5002029&i=1>
> > > Betreff: Re: [postgis-users] CityGML in PostGIS - 3D City Database
> > released
> >
> > > hi,
> > > thank you for your answer  (despite that it is a little late )
> > > I built a model of a city with CityGML and I want to queries the
> CityGML
> > > file in a database, and as 3D city database can help me in this task I
> > try
> > > to use it.
> > > I instaled this tool, 3D City Database for PostGIS 8.4 Postgersql
> > > postgis1.4.0. Purpose When I connect to the database an error is
> > displayed
> > > "failed to connect to the database, error: schema" geodb_pkg "does not
> > > exist." (the result found in the attached document)
> > > I think it is an instalation error in fact I did not Understand how to
> > > install this tool.: (
> > > I have even read all documents provided with this tool but I did not
> > find
> > > a
> > > good tutoriale explains well the instalation.
> > > I just installed 3DCityDB well-Import-Export in (C: \ Program Files)
> > then
> > > I
> > > do not know where i shoulds integrate 3Dcjtydb-2.0.6.!
> > > how come the link Between Postgersql and 3Dcjtydb-2.0.6?
> > > can you please guide me to solve this problem?
> > > and if it is possible to  make a video which explains the process of
> > > instalation and operation of 3D City Database for PostGIS?
> > > thanks for any help :)
> > > <http://postgis.17.n6.nabble.com/file/n5002027/Sans_titre.png>
> > > <http://postgis.17.n6.nabble.com/file/n5002027/citydb_PostgreSQL.png>
> > >
> > >
> > >
> > > --
> > > View this message in context:
> > >
> >
> http://postgis.17.n6.nabble.com/CityGML-in-PostGIS-3D-City-Database-released-tp4998980p5002027.html
> >
> > > Sent from the PostGIS - User mailing list archive at Nabble.com.
> > > _______________________________________________
> > > postgis-users mailing list
> > > [hidden email] <http://user/SendEmail.jtp?type=node&node=5002029&i=2>
> > > http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users
> > _______________________________________________
> > postgis-users mailing list
> > [hidden email] <http://user/SendEmail.jtp?type=node&node=5002029&i=3>
> > http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users
> >
> >
> > ------------------------------
> >  If you reply to this email, your message will be added to the
> discussion
> > below:
> >
> >
> http://postgis.17.n6.nabble.com/CityGML-in-PostGIS-3D-City-Database-released-tp4998980p5002029.html
> >  To unsubscribe from CityGML in PostGIS - 3D City Database released,
> click
> >
> here<http://postgis.17.n6.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=4998980&code=aGliYS5tYWFsYW91aUBnbWFpbC5jb218NDk5ODk4MHwxOTY3MjkzNzg4>
> > .
> >
> NAML<http://postgis.17.n6.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>
> >
> 
> 
> create_db file bat.png (84K)
> <http://postgis.17.n6.nabble.com/attachment/5002070/0/create_db%20file%20bat.png>
> batfile.png (73K)
> <http://postgis.17.n6.nabble.com/attachment/5002070/1/batfile.png>
> citydb.png (277K)
> <http://postgis.17.n6.nabble.com/attachment/5002070/2/citydb.png>
> 
> 
> 
> 
> --
> View this message in context:
> http://postgis.17.n6.nabble.com/CityGML-in-PostGIS-3D-City-Database-released-tp4998980p5002070.html
> Sent from the PostGIS - User mailing list archive at Nabble.com.


More information about the postgis-users mailing list