• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

reworking Access to mySQL

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, All.

I have a working project - a simulator of Web auction. Currently it pulls all data from a small 4-table Access DB. My question is: is it possible to change the format of the database from Access to mySQL, and what steps should I take to do that?

I'm a very, very lightweight in JDBC\Java.. So any help is GREATELY appreciated.

I'd be glad to provide you the source code of thisproject if you decide to help.

Thank you in advance,

KK
 
Sheriff
Posts: 67753
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What aspect are you confused about? Converting the data, or converting the application?

If the latter, unless you used Access-specific SQL statements (and the table structure and names are identical) your app may not need to change at all.
 
Ken Kesselman
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, There!

Thank you for replying.

I guess I'm confused in the way the application will connect to DB. As about the query statements - they are standard: SELECT, INSERT, UPDATE

Here's my DBConnect.java:



My qyuestion is how do I change that so i do not have to set up ODBC connection on the system? Basically, so it uses JDBC driver directly - smth like this:



Am I on the right track here? Can I dierctly modify my code to just change from using ODBC to just JDBC driver?

Thank you again!

Ken
[ May 19, 2005: Message edited by: Bear Bibeault ]
 
Bear Bibeault
Sheriff
Posts: 67753
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, that's the right tactic. Your JDBC driver obviously needs to tbe in the classpath, but no other system-specific setup is needed (no control panel crap or stuff like that). The JDBC URL will need to match what is expected by MySQL as well. The MySQL docs should provide that info, or those more familiar with MySQL than myself -- I usually use PostgreSQL -- can chime in.
 
Ken Kesselman
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey, Bear!

I changed my code to look like this:



Does this look right? (assuming all the URLs are correct)?

KK
 
Opportunity is missed by most people because it is dressed in overalls and looks like work - Edison. Tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic