I am facing an enormous task: I need to move data from a very old and active schema to a new schema with different table structures. The new schema is on the development machine whereas the old schema is on the web server. Both schemas are 4th degree normalized.
What tools are available in PostgreSQL to help with this? Is there a recommended way of doing this?
(I will be updating to the current version of PostgreSQL from the older 9.2 version).
Thanks for any suggestions.
Related
I have created a db long ago using django. Now as we are migrating the application, so I need all the CREATE TABLE sql queries which django might have run to create the entire db for our service (which has around 70-80 tables and each table has avg 30-70 columns).
Both the servers old and new are using Postgres for databases.
But the technology stack is completely different (A 3rd party proprietary application which will host the service) instead of django.
If I start to write all the tables again from scratch, it will take at least a week or two.
Is there any way either from Postgres or from django which can generate the CREATE TABLE sql schema for an entire db keeping all the relationship as is?
Also, I have to do minor modification to that schema as per customer requirement.
p.s - pg_dump won't work as I need actual schema itself to get it reviewed from client.
I'm trying to run a different database for development as my initial product release is coming so I'd like to know how to maintain two different databases. I'm using postgresql as my DBMS
I want development database and production database to have exactly the same schema. Is there a way to do this automatically? If I have to to manually, what would be the best way to update schema?
thank you
I want development database and production database to have exactly the same schema.
Then just create 2 databases with the same schema(s).
Or you can read more about template databases - https://www.postgresql.org/docs/11/manage-ag-templatedbs.html.
The idea is that when you create new database, it's actually copied from template1, thereof you can edit template1, and every new database will have schemas/tables that you need.
I want to keep oracle and orientdb databases in near real time sync and vice versa. Is there any tool/ mechanism to follow.
OrientDB had just released a new tool that allows exactly what you want. Its name is Teleporter and you can use it to:
Import your existing RDBMS to OrientDB.
Keep your OrientDB database synchronized with changes from the RDBMS.
This tool supports migration and sync with Oracle, SQLServer, MySQL, PostgreSQL and HSQLDB DBMSs.
Teleported has been released few days ago with the new orientdb 2.2.0-beta version and even though is not yet integrated (it isn't a definitive release) is really easy to insall.
Here is the Teleporter page on orientdb.com:
http://orientdb.com/orientdb-labs/teleporter/
and here you can find the link to the documentation:
https://github.com/orientechnologies/orientdb-labs/blob/master/Teleporter-Index.md
I have a task at hand wherein we need to compare two database schemas at two different versions.
Actually an application has been upgraded to use Oracle 11g , older version of the application used Oracle 10g. Basically what needs to be checked is the differences in the schemas of the two different versioned applications mainly to check if no functionality is broken or no relevant schema change is missed
I did some R&D and found many tools are available to compare schemas, DB Solo etc. But my requirement being to compare two schemas at 2 different versions. The tools are available to compare schemas at same version.
Some of the solutions I came up with after having discussions with seniors
1) establish a DB link between the 2 DB schemas and do a comparison of USER_OBJECTS. This solution is however not feasible for us.
2) If we can get a TEXT like dump of both the schemas, a basic text comparison would give the schema differences.
However, I do not know how Solution 2 would be possible.
I have seen some older posts like
Compare two schemas and update the old schema with the new columns of new schema but I need a more simplistic solution!
Your help is appreciated.
Did you already try "Tools"->"Database Diff" from Oracle SQL Developer ?
We have a daily process that pulls all data out of a number of tables in an Oracle database and imports them into a Postgress (EnterpriseDB) database - Version 8.4.
We are currently using a java application to select * from each table, change the keywords (date, timestamp, etc) and then import them into the Postgres Database.
Are there any tools available in Postgres that would provide a more efficient manner of doing this? I should note that there are CLOBs that are being transported over.
There is Ora2Pg, which is intended as a one-time-migration tool, but it might work in your case as well. I think of it as an Oracle-to-PostgreSQL pg_dump.