Software, your way.
burger menu icon
WillMaster

WillMaster > LibraryWebsite Development and Maintenance

FREE! Coding tips, tricks, and treasures.

Possibilities weekly ezine

Get the weekly email website developers read:

 

Your email address

name@example.com
YES! Send Possibilities every week!

The Same MySQL Database For Many Different Software Installations

If your hosting account limits the number of MySQL databases, consider using the same database for multiple different software installations.

The primary concern when using the same MySQL database for different software installations is table name clashes. Software A may use table name "usernames" and software B also use table name "usernames".

If it wasn't for table name clashes, all software might use the same database.

Some software makes it very easy to maintain unique table names. During installation, the software allows you to prefix a custom name or set of characters that will be the applied to the names of all the tables the software creates.

When installing the software to use the same database as other software does, give the new software a unique table name prefix.

Let's take Short URL V2 as an example. Here is a screenshot of the pertinent section of the installation page.

Short URL V2 installation MySQL table prefix

"shorturl_" is suggested as a table name prefix. But the prefix can be anything (or removed altogether).

You can even install the same software multiple times for using the same database by specifying a different table name prefix for each installation. Table prefixes "shorturl1_", "shorturl2_", and "shorturl3_" for example.

Probably for all software with the option of specifying a table name prefix, certainly all Willmaster software, the time to specify the prefix is during the installation process. Willmaster software asks for it on the installation page. Other software may have a different way.

When specifying a table name prefix, start it with a lower-case letter. Following that can be any combination of lower-case letters, numbers, and/or the underscore character.

WebSite's Secret members can use List All MySQL Structures to get a list of table names in a database. If you do not have membership and don't know what table names are already in the database or how to find out, including a date in the prefix is likely to ensure uniqueness. I.E., "shorturl18oct11_".

Not all software has provisions to specify a unique table name prefix. (Willmaster software does provide that option.)

For those whose hosting account limits the number of MySQL databases, software that does allow a custom table name prefix can be installed to use the same database as other software does.

Will Bontrager

Was this article helpful to you?
(anonymous form)

Support This Website

Some of our support is from people like you who see the value of all that's offered for FREE at this website.

"Yes, let me contribute."

Amount (USD):

Tap to Choose
Contribution
Method

All information in WillMaster Library articles is presented AS-IS.

We only suggest and recommend what we believe is of value. As remuneration for the time and research involved to provide quality links, we generally use affiliate links when we can. Whenever we link to something not our own, you should assume they are affiliate links or that we benefit in some way.

How Can We Help You? balloons
How Can We Help You?
bullet Custom Programming
bullet Ready-Made Software
bullet Technical Support
bullet Possibilities Newsletter
bullet Website "How-To" Info
bullet Useful Information List

© 1998-2001 William and Mari Bontrager
© 2001-2011 Bontrager Connection, LLC
© 2011-2024 Will Bontrager Software LLC