WebFaction
Community site: login faq

I am trying to run the following statement in postgres : "ALTER TABLE "public"."opportunity_talentconnection" ADD CONSTRAINT "fk_connector" FOREIGN KEY ("connector_id") REFERENCES "public"."profiles_connector"("id")"

And I am getting a Transaction Timeout after 30 seconds. opportunity_talentconnection is a brand new table and profiles_connector currently have 2341 entries.

The call was failling using django-south, so I tried to run it directly in postgres but I got the same result. I try to manually create the foreign key constraint with the GUI (phpPgAdmin) and I got the same result again.

Any idea why it is failling while it worked in other environnement also using postgres?

asked 16 Feb '11, 11:40

matchfwd
41158
accept rate: 0%


You may set the timeout value on a per-session basis with this command,

PGOPTIONS="-c statement_timeout=60000" psql -U dbname dbname
permanent link

answered 16 Feb '11, 12:37

johns
5.4k312
accept rate: 23%

Thanks for the tip. But the actual issue is the a simple alter table results in a transaction timeout. I stumble onto another problem I'm getting Transaction timeout when dropping tables to . I tried something as simple as << DROP TABLE "opportunity_jobopportunity_connectors"; >> and it failed with a Transaction Timeout too. But when I do a TRUNCATE it works. My guess is that some table logs are full on the webfaction servers;

(16 Feb '11, 12:47) matchfwd

Please submit a support ticket so we can look at the issue. Include your permission to or not to drop the table.

(16 Feb '11, 14:40) johns
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×909
×22
×18

question asked: 16 Feb '11, 11:40

question was seen: 4,466 times

last updated: 16 Feb '11, 14:40

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM