projects
/
skytools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
823f171
)
duh, more missed fields
author
Marko Kreen
<markokr@gmail.com>
Thu, 5 Apr 2007 09:49:36 +0000
(09:49 +0000)
committer
Marko Kreen
<markokr@gmail.com>
Thu, 5 Apr 2007 09:49:36 +0000
(09:49 +0000)
sql/pgq/functions/pgq.maint_rotate_tables.sql
patch
|
blob
|
blame
|
history
diff --git
a/sql/pgq/functions/pgq.maint_rotate_tables.sql
b/sql/pgq/functions/pgq.maint_rotate_tables.sql
index 0195b60520795c24e1322e46b5ff05fa0d59d7ce..f9d12367f887bdaf69d6c3b68d50d9281f2abcd4 100644
(file)
--- a/
sql/pgq/functions/pgq.maint_rotate_tables.sql
+++ b/
sql/pgq/functions/pgq.maint_rotate_tables.sql
@@
-48,7
+48,7
@@
begin
if nr = cf.queue_ntables then
nr := 0;
end if;
- tbl := cf.
table_name
|| '_' || nr;
+ tbl := cf.
queue_data_pfx
|| '_' || nr;
-- there may be long lock on the table from pg_dump,
-- detect it and skip rotate then
@@
-72,7
+72,7
@@
begin
-- clean ticks - avoid partial batches
delete from pgq.tick
where tick_queue = cf.queue_id
- and get_snapshot_xmin(
snapshot) < cf.last
_switch_step2;
+ and get_snapshot_xmin(
tick_snapshot) < cf.queue
_switch_step2;
return 1;
end;