Topic: Regarding data transfer from postgresql to sqlserver...


        I am new for ruby on rails technology.. I want to know how all data transfer from postgresql database tables to sqlserver database tables

Any ruby script available for solving this problem????....

for example,

postgresql tables              sqlserver tables

names                               names
address                             address

i want all data from names tables move to names tables in sqlserver tables... any ruby script for this problem????

with Regards,

Re: Regarding data transfer from postgresql to sqlserver...

Hrmm. Rails might be able to do this if you do some fiddling with the database connector at runtime.

You're new so lets review some basics: Rails provides a Model layer that will run on many databases. So it abstracts the data and then relies on database specific connectors to write that data to a given database.

So what I think you need to do is:
1. Get rails to run on top of your existing postgres database. Create a Rails schema and models to mirror your existing tables. Use the postgres connector in database.yml for this.

2. Ensure that rails can read all of the data you need from the postgres database. Test, test, and test again.

3. Reuse the same schema and change database.yml for your SQLServer database. Use the schema to build the tables in the target database.

4. This is the hard part, get rails to load two database connections using different connection types.

5. Find objects from postgres and save them to SQLServer.

Step #4 is the hard one, but it should be doable. Any other experts care to weigh in?