pg_dump and restore without indexes

From: "Wetmore, Matthew (CTR)" <Matthew(dot)Wetmore(at)evernorth(dot)com>
To: Teja Jakkidi <teja(dot)jakkidi05(at)gmail(dot)com>, pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: pg_dump and restore without indexes
Date: 2024-06-04 18:15:07
Message-ID: a5e117b5569b4a5cb638036405476ea7@evernorth.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

This is where custom scripting your dump comes in handy.

Inside the shell script you can dump only what you want. Specifically line by line. This is good because you don't have to touch the 'official dump' and can have all your stuff editable and restorable if needed.

Most large db's do this since order of operations can cause issues.

a separate for loop for indexes, tables, views, sequences, etc.

-----Original Message-----
From: Teja Jakkidi <teja(dot)jakkidi05(at)gmail(dot)com>
Sent: Tuesday, June 4, 2024 10:42 AM
To: pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: [EXTERNAL] pg_dump and restore without indexes

Hello Admins,

I am trying to look for an option that can be added in pg_dump command to ignore all the indexes when creating the schema dump with data.
Is there any such option that can be used in pg_dump? Or in pg_restore?

Please help with your inputs.

Thanks in advance,
J. Teja.

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Erik Wienhold 2024-06-04 18:27:08 Re: pg_dump and restore without indexes
Previous Message Teja Jakkidi 2024-06-04 17:58:24 Re: pg_dump and restore without indexes