Special

Clearance Sale!

We've been publishing for over five years now and it's time to clear out our inventory of back issues, so we're slashing prices!

RBD Magazines

Check out this amazing clearance sale of all our past issues. Missing some issues? This is a great time to complete your RBD collection. Save up to 40% off the regular price of our printed back issue packages. These prices are only good until the end of the year May 2008 and supplies are limited, so place your order today.

Article Preview


Buy Now

Print:
PDF:

REAL SQL Server

Migrating to REAL SQL Server

Issue: 5.4 (May/June 2007)
Article Description: No description available.
Article Length (in bytes): 3,660
Starting Page Number: 40
RBD Number: 5414
Resource File(s): None
Related Link(s): None
Known Limitations: None

Excerpt of article text...

One of the benefits of using REAL SQL Server is that it gives you a pretty painless way to migrate a single-user REAL SQL Database to a multi-user REAL SQL Server database. How is this possible? If you recall from the last column, REAL SQL Server is also built on top of SQLite. In fact, it actually uses your REAL SQL Database files with no modification to get them on the server!

However, you will likely have to change some of your code in order to get it to work with the server.

Migrating Existing Code

When you wrote your original code, you likely used the REALSQLDatabase class. This makes sense, since that was the database you were working with. That design decision will require you to change some of your code to make it server aware, though. We'll see in the next section how you can design your code so that it can be either single-user or multi-user.

The first thing you need to do is make sure the REALSQLServer plugin (REALSQLServerPlugin.rpx) is installed in your plugins folder. Next, you need to find all the references to the REALSQLDatabase class and change them to refer to the REALSQLServerDatabase class. Lastly, you need to change how you connect to your databases. Previously your code probably looked something like this:

...End of Excerpt. Please purchase the magazine to read the full article.

Article copyrighted by REALbasic Developer magazine. All rights reserved.


 


|

 


Weblog Commenting and Trackback by HaloScan.com