CMDBuild Forum

Relation "Gis_Building_Position" does not exist

After a lot of repeated attempts, I am able to install Openmaint 3.1.1 on Windows 7 in my workstation.
During modeling and data entry, I have marked the position of a building on map and saved it successfully. But whenever I try to save it again with some data change or even without any data change, I get error at right bottom corner popup and it shows following error message.

org.cmdbuild.dao.DaoException: error executing update for entry = CardImpl{id=296626, code=CPX001-BLD001, type=Building}, caused by: org.springframework.jdbc.BadSqlGrammarException: StatementCallback; bad SQL grammar [UPDATE “Building” SET “Code” = ‘CPX001-BLD001’, “Description” = ‘CPX001-BLD001 - CPX001 Main Gate’, “Name” = ‘CPX001 Main Gate’, “MainUse” = 295504, “Complex” = 291639, “Address” = ‘Bhauri’, “ZIP” = ‘462016’, “City” = ‘Bhopal’, “TotalGrossArea” = NULL, “Condition” = 30, “Criticality” = 34, “TotalNetArea” = NULL, “CoveredArea” = NULL, “GlazedArea” = NULL, “CleanableArea” = NULL, “TotalVolume” = NULL, “TotalHeatedVolume” = NULL, “State” = 287181, “CleanableWallArea” = 600.0, “TotFloors” = NULL, “TotRooms” = NULL, “Notes” = NULL WHERE “Id” = 296626]; nested exception is org.postgresql.util.PSQLException: ERROR: relation “Gis_Building_Position” does not exist Where: PL/pgSQL function _cm3_trigger_card_enforce_foreign_key_for_target() line 5 during statement block local variable initialization, caused by: org.postgresql.util.PSQLException: ERROR: relation “Gis_Building_Position” does not exist Where: PL/pgSQL function _cm3_trigger_card_enforce_foreign_key_for_target() line 5 during statement block local variable initialization

Gis_Building_Position-error

Any idea what is going wrong?

In versions prior to OpenMAINT 2.0 - 3.1.1 there was a bug in the command line that restores the databases, the search_path setting was missing.
In the latest version this bug has been fixed, but if the error still comes up you can run the following command:
ALTER DATABASE [database_name] SET search_path = “$user”, public, gis;
and then restart Tomcat.

Thank you very much.:slightly_smiling_face: It sorted the issue.
Just FYI, I am working on Openmaint populated with dump named “openmaint_empty_gis.dump”.