Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Oct 2011
    Posts
    14
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Can MySQL work for both desktop GUI and web app together?

    Guys I am creating a project. It's a management system which has customer registration done using a Java GUI and a Web Site. Both the website and the Java GUI do the same things while registering.

    I decided in using MySQL for this and wanted to make sure whether can both use the same DB and update the same tables? can MySQL workbench support both a Java GUI and a website?

    Thank You for your help

  • #2
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    25,537
    Thanks
    77
    Thanked 4,381 Times in 4,346 Posts
    Ummm...MySQLWorkbench *is* a Java GUI, you know. (Or maybe it's a C++ GUI, but since it came from Sun originally I'd bet on Java.)

    In any case, what would MySQLWorkbench have to do with the question?

    I, for one, still use the command line interface for virtually everything I do with MySQL. (Yes, I even use it for CREATE TABLE and for writing stored procedures.)

    The *tool* you use to create and administer the database has nothing to do with any other application that *uses* the database.

    So the short answer to your question is: YES!

    The longer answer: You could use the same database with Java, with JSP, with PHP, with ASP, with ASP.NET, with C++, with Python, with ... Well, with any client. **ALL AT THE SAME TIME**.

    Understand that MySQL is a *server*. It runs in its own process. All these other programs (yes, including a WEB server) run in *their* own processes. They NEVER share the process with MySQL. Instead, commands and data are passed back and forth between the applications and the MySQL server via some communications channel. That's what the "port number" you see associated with MySQL is for: the "channel" by which it communicates with applications.

    Incidentally, MySQLWorkbench is *NOT* special in any way. It, too, runs in its own process space and communicates with MySQL the same way. If you wanted to, you could create your own "ChettyWorkbench" that would duplicate all the MySQLWorkbench does.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •