[baseten-users] Migrating legacy databases to BaseTen

Tuukka Norri tuukka.norri at karppinen.fi
Tue Oct 6 02:21:34 EEST 2009


Tiago Ribeiro kirjoitti 29.9.2009 kello 21.29:
> Question, what would be the most appropriate way to migrate an  
> existing database that we already have to BaseTen? Considering the  
> fact that the tables, fields and relationships are already set and  
> usually cannot be changed.

Hi and sorry about the delay.

BaseTen has been designed to require minimal changes to an existing  
database. Tables from which objects are fetched do need to have  
primary keys, but they may consist of multiple columns and may have  
any type that Postgres allows. Not having exceptionally large primary  
keys is an advantage, though. Relationships are deduced from foreign  
keys even when creating the schema using BaseTen Assistant. Views have  
some additional requirements but I'd expect creating them to be more  
feasible than changing tables in case of an existing database. See  
sections 2.1, 2.5 and 2.7 in the reference manual for details.

While BaseTen needs some additional tables, they are placed into a  
schema called baseten, so that they will be separated from everything  
else. To make use of change notifications, triggers will need to be  
installed into existing tables. The triggers reference the schema as  
well, so Postgres will remove them with the schema if needed.
-- 
Best regards,
Tuukka Norri
MK&C




More information about the baseten-users mailing list