Click to See Complete Forum and Search --> : Using JDBC with MySQL ...getting started
brf132
Nov 29th, 2006, 11:25 PM
Hi all-
New to VB forum, my dad and all of the people in my group for school use this site so I figure ill give it a try.
We are developing a system for a Pizza Shop that is supposed to be dynamic with: On-line ordering, Supply/Inventory Management, In Store orders, employee payroll management. The database doesnt HAVE to be in mySQL but we think that is the best option. I am just looking for any suggestions on how to start this and make it all be functional. Anyone with any ideas on how to help would be greatly appreciated.
Thanks
Brian Frick
PSU '08
CornedBee
Nov 30th, 2006, 05:33 PM
If you want to use MySQL, be sure to get a very recent one - at least 5.0. Versions earlier than that don't support transactions and thus are not suited to high-fidelity jobs such as on-line ordering or payroll management.
Or get PostgreSQL, which is slower than MySQL, but much more mature in terms of features.
Another free option is HSQLDB.
But the nice thing is that all databases are handled pretty much the same in Java: through JDBC. You get the database driver, you register it, you call DriverManager.getConnection() with an appropriate DSN. Or you create a resource in the servlet container and get a DataSource via JNDI. Either works.
So, how to start? Well, I suppose the best way is to learn SQL if you don't know it and then do some small example programs in Java.
There's always the highly reliable tutorials on Sun's site.
http://java.sun.com/docs/books/tutorial/jdbc/
brf132
Nov 30th, 2006, 07:40 PM
CornedBee-
Thanks for the reply, although you went into more detail than I need. I feel that I asked a question that put me in over my head from the first minute. Right now we are still in theory of creating this actual project, and it is due within 3 weeks time (Dec 22). We have created the GUI but I really don't know how to input data through java. I took plenty of courses in C++ and, although I am not an expert, I am much more skilled in that than Java. I changed campuses and apparently the Pre-req course for my java class was supposed to have taught us into -java, but it never did. That pretty well screwed me :).
I would like to know how to simply get data from the user in a GUI, and maybe store it in an array or something that I could then send into a DB, any kind of DB, could be a hash table, text file, pretty much anything that can hold information and be accessed, through java later. If you, or anyone else would like to send me some help or give me some of your time, it would be greatly appreciated, as I would fully enjoy to not fail my first class of my collegiate carreer. Thanks again for your time
brf132
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.