1.2 Beta overwrote old database

1.2 Beta overwrote old database

by Thomas Bray -
Number of replies: 4
Hi all:

Knowing that I know nothing, (which is always good to know smile, I long ago set up a moodletest site where I could test installs and upgrades before blundering onto my active sites.

I installed the 1.2 beta, and rather than upgrading the old moodle, it installed clean. All the data base info (location, password, name, etc) were placed into the config file, but--no luck.

Any ideas why?

smile

TB
Average of ratings: -
In reply to Thomas Bray

Re: 1.2 Beta overwrote old database

by Jacob Romeyn -
Could this be the problem?thoughtful

Did you use a new config.php file?  And not  disable the CFG->prefix = "mdl_": , the "old" Moodlle did not have this.

If you therefore add mdl_ in front of all your database tables you will have a complete new install.

To fix this put a # in front of the line in the config.php file as:
#CFG->prefix ="mdl_"

In reply to Jacob Romeyn

Re: 1.2 Beta overwrote old database

by Thomas Bray -
Yes, I'm quite certain that is the problem. sad I wondered about that when I saw that line in the new config.

So, if I comment out that line, it won't rename the files, correct?

Thanks,

Thom
In reply to Thomas Bray

Re: 1.2 Beta overwrote old database

by Thomas Robb -
It isn't a matter of 'renaming files'. Moodle never does that.

If your original config said said that the prefix was "mdl_" then all of the tables in the database will have names starting with "mdl" such as "mdl_forum" and "mdl_forum_postings". If you change that so that there is no prefix, then Moodle will create a full new set of tables with names that don't contain a prefix, such as "forum" and "forum_postings".

You can actually have more than one site in the database. All you need to do is to change the prefix in the config file and the other site will come up.