Page 1 of 1

Database

PostPosted: Sun Dec 07, 2003 5:06 pm
by Carbonite
Hey =)
hrhr finally found your secret little place here :twisted:

errrr anyways.. i was talking to syn about a good Database and he suggested to ask either Brammer or Zane now instead of anoying the hell out of both i decided to anoy everyone =)

Ohh and this will be for VB (as i dont understand C++ that good yet)
soooo tell me what DB is best for VB ?? (not for online applications)

PostPosted: Sun Dec 07, 2003 6:02 pm
by Brammers
Ahh damm we are not alone! Is that the real Carbonite I know? Anyway, welcome .:)

Databases, well I need some more information. Is it a little application that needs a DB backend, and how many users are you expecting and how much data are you expecting?

For start, if you use ADO in VB all database connections go via the ODBC. So later on if can change the database from say Access to SQL Server, without changing the application. But generally my rule of thumbs goes.

For small data and not many users use a Access MDB file.
For lots of data, many users, go for something more powerful such as Oracle or SQL server.
And if you are feeling brave go for a MySQL backend!

PostPosted: Sun Dec 07, 2003 8:15 pm
by Carbonite
ok i dont know much about DB's but can you use MySQL for offline applications aswell ??

and ya im Carb teh GM ;)

PostPosted: Sun Dec 07, 2003 10:59 pm
by Thonkus
as shitty as MS Access is, it is practically written to go hand in hand with VB, so the decision is primarily how large the DB will be at the end of it's life. Larger than 10 megs....use something other than MS, it get's all picky.

Re: Database

PostPosted: Mon Dec 08, 2003 1:29 am
by Syntax-Error
Carbonite wrote:Hey =)
hrhr finally found your secret little place here :twisted:


Oh god what have i done :shock:

PostPosted: Tue Dec 09, 2003 9:09 am
by Richard Parker
MySQL is more an more a truly Uber solution to databases. The price is right (free), and the windows version (free) is totally compatible with the Unix version.

Now just in case there are any idiots out there that think MySQL can't scale, I've built MySQL databases that had more than a million records, replicated across 3 clusters of 3-5 machines (each cluster) more than 3000 miles apart. Each database (individual machine in the cluster) handled up to 70 lookups per second at peak volume. This volume of data transfer required FC storage (only 1TB per cluster, but FC was *expensive* back then) because normal RAID couldn't quite keep up with the IO.

I've had MS SQL servers that have crumbled under a quarter of that volume. For this project, the company I worked for had investment from Microsoft, so I was unfortunately required to duplicate my efforts under MS SQL as well. When we demonstrated the... errrm... failings of MS SQL to Microsoft, they didn't say another word about us using MySQL.

To save on dev time and pain, I typically design my database locally under windows, and replicate the structure to the live database (generally a linux server sitting out on the net somewhere). The application is developed using ODBC. By structuring things like this from the start I can simply flip a switch and test against either the live database, or the test (local) database.

Since just about every single programming language support ODBC these days it's a no brainer.

So, to sum it up, if you're serious about your project, take a good look at MySQL. It's a bit more work to get set up for a VB project than MS SQL or Access (hell, with .NET shit just happens if you do an install of *Everything* :shock: ) but it's *very* worth it.

On the other side of the coin, you might want to evaluate closely if you really need a database or not. Anything under around 2000 rows (depending on the data) can just as easily be dumped into a CSV file. In fact there are even some languages (Perl for example) that will allow you to bind a CSV file as if it were a database, and actually make SQL calls to it. This is another really handy way of scaling a project up to actualy using a DB before setting out and dealing with the implementation of a potentially complex schema.

Bah, orignally I was just going to point you at the windows version of MySQL and say "MySQL good! Microsoft BAD!". If you would like help working with MySQL, let me know, I've been using it for at least 8 years.

PostPosted: Tue Dec 09, 2003 11:14 pm
by Carbonite
Yes please :wink: Im a total n00b regarding most databases and i dont know anything about MySQL...

Well the DB wont be that large... not for this project i got going anyways...
I wanna do another project that will need a larger DB but i wont think about that now hrhr

PostPosted: Wed Dec 10, 2003 9:30 am
by Archeus
Depends on what you want to do. MySQL is fine, if you want some pretty basic there is csvjdbc which turns a directory into a DB and delimted text files into tables.

PostPosted: Wed Dec 10, 2003 7:08 pm
by Zane
Erm.. ok.. so I've been away and the result is.. I've missed lots of posts and threads I could have spammed. Fortunately for you, you happened to stumble upon a bunch of nerd.....er.. programmers.

Basically, Carb, What they said.

I'm writing PNPT (Phoenix Network Production Tool) now. It's a distributed system, in that each client connects via TCP to the server, the server itself interacts with the database.

There are several different ways to access a database through VB. But essentially, anything worth it's salt will access data in an SQL type fashion.

Because I only have one 'user' (the server) accessing the database at any one time, and it's not going to be load intensive, I'm sticking to a bog standard MDB.

(The hard part is going to be synchronising clients local databases with the master server DB.. oooh.. fun.

Oh.. and welcome to the THN