ankane/pgsync

Table not found in source: true

andr-c opened this issue · 1 comments

Hi,
I'm getting Table not found in source: true no matter which option I tried:

  • pgsync --from db1 --to db2 --to-safe true
  • pgsync --from db1 --to db2 --to-safe true --schemas foo
  • pgsync --from db1 --to db2 --to-safe true --schemas foo --schema-only
  • pgsync --from db1 --to db2 --to-safe true --schemas foo --schema-first

All commands are reporting same result. What I could be doing wrong?
I'm running stock docker image - ankane/pgsync.

Here is the output with the debug option:

[from] SELECT table_schema AS schema, table_name AS table FROM information_schema.tables WHERE table_type = 'BASE TABLE' AND table_schema NOT IN ('information_schema', 'pg_catalog') ORDER BY 1, 2
/usr/local/bundle/gems/pgsync-0.7.3/lib/pgsync/task_resolver.rb:187:in `fully_resolve': Table not found in source: true (PgSync::Error)
	from /usr/local/bundle/gems/pgsync-0.7.3/lib/pgsync/task_resolver.rb:41:in `block in tasks'
	from /usr/local/bundle/gems/pgsync-0.7.3/lib/pgsync/task_resolver.rb:40:in `each'
	from /usr/local/bundle/gems/pgsync-0.7.3/lib/pgsync/task_resolver.rb:40:in `tasks'
	from /usr/local/bundle/gems/pgsync-0.7.3/lib/pgsync/sync.rb:46:in `perform'
	from /usr/local/bundle/gems/pgsync-0.7.3/lib/pgsync/client.rb:26:in `perform'
	from /usr/local/bundle/gems/pgsync-0.7.3/lib/pgsync/client.rb:35:in `start'
	from /usr/local/bundle/gems/pgsync-0.7.3/exe/pgsync:7:in `<top (required)>'
	from /usr/local/bundle/bin/pgsync:25:in `load'
	from /usr/local/bundle/bin/pgsync:25:in `<main>'

Hey @andr-c, change --to-safe true to --to-safe (remove the true).