Обсуждение: extracting PII data and transforming it across table.

Поиск
Список
Период
Сортировка

extracting PII data and transforming it across table.

От
Suresh Raja
Дата:
Hi Folks:

I'm looking at directions or help in extracting data from production and alter employee id information while extracting.  But at the same time maintain referential integrity across tables. Is it possible to dump data to flat file and then run some script to change emp id data on all files.  I'm looking for a easy solution.

Thanks,
-Suresh Raja

Re: extracting PII data and transforming it across table.

От
Steve Midgley
Дата:
I would update the IDs using SQL before dumping if possible. If necessary clone the tables, adjust the IDs and then dump. SQL has better tools than most languages/scripts to adjust values in columns across multiple entities. Plus it should be easier to build some test queries in SQL to validate that your ID adjustments were valid.

On Thu, May 21, 2015 at 9:27 AM, Suresh Raja <suresh.rajaabc@gmail.com> wrote:
Hi Folks:

I'm looking at directions or help in extracting data from production and alter employee id information while extracting.  But at the same time maintain referential integrity across tables. Is it possible to dump data to flat file and then run some script to change emp id data on all files.  I'm looking for a easy solution.

Thanks,
-Suresh Raja

Re: extracting PII data and transforming it across table.

От
Suresh Raja
Дата:
On Thu, May 21, 2015 at 11:33 AM, Steve Midgley <science@misuse.org> wrote:
I would update the IDs using SQL before dumping if possible. If necessary clone the tables, adjust the IDs and then dump. SQL has better tools than most languages/scripts to adjust values in columns across multiple entities. Plus it should be easier to build some test queries in SQL to validate that your ID adjustments were valid.

On Thu, May 21, 2015 at 9:27 AM, Suresh Raja <suresh.rajaabc@gmail.com> wrote:
Hi Folks:

I'm looking at directions or help in extracting data from production and alter employee id information while extracting.  But at the same time maintain referential integrity across tables. Is it possible to dump data to flat file and then run some script to change emp id data on all files.  I'm looking for a easy solution.

Thanks,
-Suresh Raja

Steve:
I too would like to update the id's before dumping.  can i write a sql to union all tables and at the same time create unique key valid across tables.

Thanks for prompt reply.

Re: extracting PII data and transforming it across table.

От
Suresh Raja
Дата:
Hi All:

Does postgresql support schema analyze.  I could not find analyze schema anywhere.  Can we create a function to run analyze and reindex on all objects in the schema.  Any suggestions or ideas.

Thanks,
-Suresh Raja