Re: Oracle to Postgres - Transform Hash Partition - Thanks!

2024-06-11 Thread David Barbour
First post to this list, and am sure it won't be my last, but you guys rock! Took a bit from all three replies and got the transformation working seamlessly. Created temp table. Copied data into temp from original (just in case!) Created partitioned table using modulus 8. Imported the data into th

Re: Oracle to Postgres - Transform Hash Partition

2024-06-07 Thread Laurenz Albe
On Thu, 2024-06-06 at 11:28 -0500, David Barbour wrote: > Been an Oracle DBA for quite a while and we're moving from Oracle to Postgres. > > I have a table that I need to transform into a hash partitioned table. > I've gone through all the steps to create a hash partitioned table, with 8 > partit

Re: Oracle to Postgres - Transform Hash Partition

2024-06-06 Thread Muhammad Ikram
Hi David, Here is another approach. See if it serves your purpose postgres=# create schema idev; CREATE SCHEMA postgres=# postgres=# postgres=# CREATE TABLE idev.assessment_result_2023_dab ( district_oid int, -- other columns go here column1 numeric, column2 numeric ); CREATE TAB

Re: Oracle to Postgres - Transform Hash Partition

2024-06-06 Thread Christoph Moench-Tegeder
## David Barbour (dbarb...@istation.com): > Now I need to 'attach' the original table. The problem I'm running into is > there are no good examples of how to define the values. The syntax is the same as with CREATE TABLE ... PARTITION OF, e.g. ALTER TABLE parent ATTACH TABLE part FOR VALUES WITH

Oracle to Postgres - Transform Hash Partition

2024-06-06 Thread David Barbour
Hi, New to this list and to Postgres. Been an Oracle DBA for quite a while and we're moving from Oracle to Postgres. I have a table that I need to transform into a hash partitioned table. I've gone through all the steps to create a hash partitioned table, with 8 partitions such as create table