• Welcome to Overclockers Forums! Join us to reply in threads, receive reduced ads, and to customize your site experience!

SQL Database

Overclockers is supported by our readers. When you click a link to make a purchase, we may earn a commission. Learn More.
Access is ok, but if money is the problem, you should really look into Firebird SQL. It is free for commercial development, and you can even embed it into your app so you would only need to distribute a database file.

Of course, as was said above, it will only be a matter of time before your clients want the app to work across a network. At that point, you are going to need to install some sort of central database server. If you used embedded Firebird, all you will have to do is install the firebird server onto a central machine, move the database file there, and then update the connection strings in your application.

SQL Express is not bad, but I do believe it throttles the speed when more than a few things are going on at once.
 
If you do not want to make any changes to your application, just follow the advice of some of the previous posters and install SQL Express 2005 onto the client machines. Then you will just need to make a backup of the database you have now and restore it into the SQL Express servers. That, or you could write an installer with a few DDL scripts to create your database after installing SQL Express.

Edit: One more option. If this is strictly a single PC app, you can use XML files. ADO.net supports saving and loading from XML. You can just use the XML files as if they are a database, and ADO.net will let you do that pretty transparently.
 
First, as far as saving your changes goes. When you added the datagrid, you probably only added a SELECT command to your dataset which basically gives you a readonly view of your database. To be able to modify the underlying data, you will need to add INSERT, UPDATE, AND DELETE commands to your dataset. Performing the "saves" (inserts, updates, and deletes) is a broad topic with many possiblities on how to determine exactly what should be saved that you really need to spend some time reading some reading some well written information (a good book or online resource) on the subject. However, basic updates are somewhat simple and this should point you in the right direction. As another possiblility, you could generate your own SQL statements and use a Command object to execute them. The dataset will need to be refreshed to see the changes. This is basically what the dataset will do, but is handles a lot of the work for you once you get it set up properly.

As far as XML is concerned, I would stay away from that for all be the smallest of databases. It's performance will quickly degrade as the size of your database grows. XML is text. At one time (for those of your that remember dBase and the like) databases were stored as text. Eventually the industry learned and moved to databases stored in binary format.

Mark
 
OK thx i will look into all of these options. I must read thru the terms and conditions of SQL Sever Express to whether i can distribute it with my apps.

Thanks Guys
 
SQL Server Express may be free, but it has size limitations, which can be very bad if this program wishes to expand any more than that limit (which is small).

MySQL is free, but not for commercial use, or even porting it "within" a program (so the user wouldn't need the SQL engine).

I would recommend something that someone else has already recommened, Firebird SQL, because you can both use it for free comercially and port it with your application.
 
Back