This is a migrated thread and some comments may be shown as answers.

Update database in client PC

2 Answers 45 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Jürgen
Top achievements
Rank 1
Jürgen asked on 26 Sep 2011, 12:43 PM
Hello Telerik!
I use ORM for my FIrebird 2.0 database in my application.
My application V.1.0 with database is installed in client PC.
When I update my application for V.2.0 of course database will be changed too.
Some tables can be removed, in some fields can be changed type, some new data can be filled, etc.
How I can update old client database to new?
Can you some examples for this?
Thanks!

2 Answers, 1 is accepted

Sort by
0
Jürgen
Top achievements
Rank 1
answered on 28 Sep 2011, 07:23 AM
If I understand right I have to create SQL-scripts with differents between database V.1.0 and database V.2.0.
I can save it to file and during App Installation - perform DBUpdate using this script from file.
And now my question - How I can Execute script from file?
Have you any code examples?
Thanks!
0
Accepted
Ivailo
Telerik team
answered on 29 Sep 2011, 08:04 AM
Hi Jürgen,

In general you are heading the right way - you can migrate your database by creating scripts that will cover all the differences in your schema. There are some possible problems that you should have in mind, including, but not limited to:

- Currently Telerik OpenAccess ORM supports only version 2.0 and 2.1 of Firebird.
- There might be specifics in the Firebird databases when migrating from version 1 to version 2, which we are not aware of - better search the documentation of Firebird for that matter.
- Telerik OpenAccess ORM can detect schema differences in the Update Database from Model wizard. So if you have a Domain Model, it can be applied on the new database. However, the script that is generated never deletes columns or tables - it only adds new ones or updates the current schema objects. That means you will have to add the delete statements manually.
- You should also think whether you need data migration and how you can achieve it. We are not providing any tools for that.

You can execute the scripts created by OpenAccess ORM directly from the Update Database from Model wizard, once you have connected to the target Firebird database. Unfortunately we don't have any examples for using Firebird client applications instead of the wizard.

Do not hesitate to let us know if you need further clarifications.


All the best,
Ivailo
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's SQL Server Community Awards. We are competing in TWO categories and every vote counts! VOTE for Telerik NOW >>

Tags
General Discussions
Asked by
Jürgen
Top achievements
Rank 1
Answers by
Jürgen
Top achievements
Rank 1
Ivailo
Telerik team
Share this question
or