[Nitro] invalid format for pg sequence query - SELECT nextval('"ogsimpletest"_oid_seq')

Reid Thompson Reid.Thompson at ateb.com
Mon Dec 17 09:24:56 EST 2007


>From current repo...
Looks like the select for the sequence has double quotes that shouldn't be there

rthompso at raker ~ $ ruby simplePG.rb 
 INFO: Og uses the Postgresql store.
DEBUG: Og manageable classes: [SimpleTest]
DEBUG: CREATE TABLE "ogsimpletest" ("date" text, "ts" text, "oid" serial PRIMARY KEY) WITHOUT OIDS
DEBUG: SELECT * FROM "ogsimpletest" LIMIT 1
DEBUG: SELECT nextval('"ogsimpletest"_oid_seq')
ERROR: DB error ERROR:  invalid name syntax
, [SELECT nextval('"ogsimpletest"_oid_seq')]
ERROR: /home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/adapter/postgresql.rb:119:in `exec'
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/adapter/postgresql.rb:119:in `query_statement'
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/store/sql.rb:572:in `query'
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/adapter/postgresql.rb:152:in `insert'
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/store/sql.rb:102:in `og_insert'
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/store.rb:94:in `save'
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/model.rb:69:in `save'
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/manager.rb:118:in `with_store'
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/model.rb:68:in `save'
simplePG.rb:36
/home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/store/sql.rb:615:in `handle_sql_exception': Og::StoreException (Og::StoreException)
	from /home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/store/sql.rb:575:in `query'
	from /home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/adapter/postgresql.rb:152:in `insert'
	from /home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/store/sql.rb:102:in `og_insert'
	from /home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/store.rb:94:in `save'
	from /home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/model.rb:69:in `save'
	from /home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/manager.rb:118:in `with_store'
	from /home/rthompso/src/repo.nitroproject.org/script/lib/../../og/lib/og/model.rb:68:in `save'
	from simplePG.rb:36



More information about the Nitro-general mailing list