Alan and André, Thank you very much for your assistance. My script takes a long log file, parses it, puts the data to a database. The application has a GUI interface and uses the data in the database to make and display various calculations and graphs. Users will have their own log files...but to use my tool, I need to either ensure they have a db server (like noted below) to create my db on...or to somehow provide a db for them to use with my tool.
1. how do I create a database that is not in users localhost? Currently I just use MySQL's "create [database]" command after I connect using MySQLdb.connect Alan mentioned something about "Do you not use an environment variable or config file to allow the user to select where the database server runs?" --> This sounds like it might be an excellent solution, but I'm not sure how to do it. 2. I also like the idea of writing a script to check to see if MySQL is installed. However, I need pointers on writing this script and also the script to auto install MySQL on another user's computer. Thank you again for your help and brilliant ideas! Lauren -----Original Message----- From: andré palma [mailto:andre...@gmail.com] Sent: Sunday, March 22, 2009 7:29 AM To: Lauren Snyder Subject: Re: [Tutor] Distributing MySQL with my application Hi! It depends for what do you want for your aplication. How about you create a database anywhere else(not in users localhost) for each user who uses your software? This way you just wouldn't have this problem. But if you really need the database on localhost my suggestion is: - make a script that check if the user already have MySQL installed, this way you just need to create an new database on localhost server for your software. if there is no MySQL : - make a script to install MySQL locally Lauren Snyder wrote: > > Hello! > > I have written an application in python that uses a MySQL database. I > want to distribute this application to many users so I created an > executable using GUI2exe. My executable works marvelously. However, > when attempting to run the app on a computer that doesnt have the > MySQL server running, I obviously get the error: Cant connect MySQL > server on localhost. > > So I have some questions around this problem: > > 1. Is it possible to bundle the database into my application? > 2. Do I have to write a script that installs the database server > locally? > 3. Do I have to make Users must have MySQL server running as a > pre-requisite for using my software? > 4. Did I miss an option in GUI2exe that allows me to set up my exe > to use MySQL? > > Thank you, > > Lauren > > ------------------------------------------------------------------------ > > _______________________________________________ > Tutor maillist - Tutor@python.org > http://mail.python.org/mailman/listinfo/tutor > _______________________________________________ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor