Bug report #717

Problem creating new column for postgis

Added by Marco Hugentobler over 17 years ago. Updated about 15 years ago.

Status:Closed
Priority:Low
Assignee:Marco Hugentobler
Category:Digitising
Affected QGIS version: Regression?:No
Operating System:All Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:10776

Description

Trying to add a column to a postgis-table. This seems to work as
expected inside the
GUI, but after deleting the layer, reload it, the column does not
appear.
in psql the column is not there ether.

This is the output inside the console during the creation-process:

Debug: qgspostgresprovider.cpp: 881: (reset) Setting up binary cursor:
declare qgisf binary cursor for select "gid",asbinary("the_geom",'NDR')
as qgs_feature_geometry from "public"."gewaesserflaechen"
Debug: qgsmaplayer.cpp: 127: (name) QgsMapLayer::name: returning name
'gewaesserflaechen
Warning: inserting attribute testcolumn of type double precision
Warning: numCols: 7
WARNING: there is already a transaction in progress
Debug: qgspostgresprovider.cpp: 881: (reset) Setting up binary cursor:
declare qgisf binary cursor for select "gid",asbinary("the_geom",'NDR')
as qgs_feature_geometry from "public"."gewaesserflaechen"
WARNING: there is no transaction in progress
WARNING: there is already a transaction in progress Debug:
qgspostgresprovider.cpp: 1992: (addAttributes)
ALTER TABLE "public"."gewaesserflaechen" ADD COLUMN testcolumn double
precision
Debug: qgspostgresprovider.cpp: 881: (reset) Setting up
binary cursor: declare qgisf binary cursor for select
"gid",asbinary("the_geom",'NDR') as qgs_feature_geometry from
"public"."gewaesserflaechen"
WARNING: there is no transaction in progress
WARNING: there is already a transaction in progress
Debug: qgspostgresprovider.cpp: 881: (reset) Setting up binary cursor:
declare qgisf binary cursor for select "gid",asbinary("the_geom",'NDR')
as qgs_feature_geometry from "public"."gewaesserflaechen"
WARNING: there is no transaction in progress

Is this a problem in the configuration of the postgres-server or inside
QGIS?

This is tested with qgis 0.8.0 and checkout of release
0.8.0-branch against
postgis_full_version
-------------------------------------------------------------------------------------
POSTGIS="1.2.1" GEOS="3.0.0rc4-CAPI-1.3.3" PROJ="Rel. 4.5.0, 22 Oct
2006" USE_STATS

Thanks for any tips.

Best
Stephan

History

#1 Updated by pcavallini - over 17 years ago

same in 0.9

#2 Updated by Marco Hugentobler over 17 years ago

Hm, I tried it today with current svn () and it worked for me. There have been some changes in adding/removing postgis columns during the last month. Could you test if you still have this problem with updated svn version? If yes, what was the type of the added column?

Marco

#3 Updated by Marco Hugentobler about 17 years ago

  • Resolution set to fixed
  • Status changed from Open to Closed

Works for me. Please reopen this bug if it does not work for you.

Marco

#4 Updated by Anonymous about 15 years ago

Milestone Version 0.9 deleted

Also available in: Atom PDF