Upgrade from 2.0.22 to 3.1.12

Get help with installation and running phpBB 3.1.x here. Please do not post bug reports, feature requests, or extension related questions here.
Get Involved
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

NOTE: phpBB 3.1.x is at its End of Life stage and support will NOT be provided after July 1st, 2018.
User avatar
open-your-eyes
Registered User
Posts: 94
Joined: Mon Jul 31, 2017 8:20 am
Contact:

Upgrade from 2.0.22 to 3.1.12

Post by open-your-eyes »

Hi!

I have an old database from a 2.0.22 board wich I want to convert to 3.1.12 (wich I have already installed succesfuly). The problem is when I try to import 2.0 database I get this error:

Code: Select all

Error

SQL query:

INSERT INTO f762dce_search_wordlist( word_text, word_id, word_common )
VALUES (
'independent', '2214', '0'
);

MySQL said: Documentation
#1062 - Duplicate entry 'independent' for key 'PRIMARY' 
I think the solution is to cancel the whole f762dce_search_wordlist table. But I don't know how. Maybe with # or /* before and after this table. But I'm not sure wich one is it. Wich character I should put to cancel the whole table?
The table is 40MB, so is not small.
Thank you.
Regards.
User avatar
warmweer
Jr. Extension Validator
Posts: 11274
Joined: Fri Jul 04, 2003 6:34 am
Location: Van Allen Bel ... gium
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by warmweer »

open-your-eyes wrote: Mon Feb 19, 2018 1:12 pm The problem is when I try to import 2.0 database I get this error:
Why on earth are you trying to import all old database into a new database 2 upgrades higher? That's bound to fail since tables, fields and attributes are different.

The correct way to upgrade = https://www.phpbb.com/support/docs/en/3 ... /upgrade2/
Alternatively (but not necessary) id to upgrade to 3.0 first and then to 3.1

Something else though.. why upgrade to 3.1 when that is nearing end of life (and end of support).
My suggestion is to upgrade to 3.2.1 (not 3.2.2 immediately). Once you have a 3.2.1 ready and functional, then try 3.2.2 (but keep a backup).

BTW the search tables can be emptied, since these can be filled once you have 3.2.1 (or higher) running. (and 40 MB is not large).
Spelling is freeware, which means you can use it for free.
On the other hand, it is not open source, which means you cannot change it or publish it in a modified form.


Time flies like an arrow, but fruit flies like a banana.
User avatar
open-your-eyes
Registered User
Posts: 94
Joined: Mon Jul 31, 2017 8:20 am
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by open-your-eyes »

I have to first import phpBB2 database and only after that I can upgrade to 3.1. I did it before. 1-2 years ago. I just don't remember how...
User avatar
open-your-eyes
Registered User
Posts: 94
Joined: Mon Jul 31, 2017 8:20 am
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by open-your-eyes »

Okay, so I tried to comment out all instances of f762dce_search_wordlist by replacing all instances of INSERT INTO f762dce_search_wordlist with //f762dce_search_wordlist. But is no good. I get this error:

Code: Select all

Error

There seems to be an error in your SQL query. The MySQL server error output below, if there is any, may also help you in diagnosing the problem

ERROR: Unknown Punctuation String @ 48
STR: //
SQL: 

#
# Table Data for f762dce_search_wordlist
#
//
INSERT INTO f762dce_search_wordlist (word_text, word_id, word_common) VALUES('phpbb', '3', '0');


SQL query:

# # Table Data for f762dce_search_wordlist # // INSERT INTO f762dce_search_wordlist (word_text, word_id, word_common) VALUES('phpbb', '3', '0');

MySQL said: Documentation
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '//
INSERT INTO f762dce_search_wordlist (word_text, word_id, word_common) VALUES(' at line 4 
I can't figure out how to comment out search tables wich I do not need anyway. :(
Help! Please!!!
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by 3Di »

open-your-eyes wrote: Mon Feb 19, 2018 2:45 pm I have to first import phpBB2 database and only after that I can upgrade to 3.1. I did it before. 1-2 years ago. I just don't remember how...
No, you must convert the b2 DB to b3, running the converter shipped with the package.
docs/INSTALL.html#convert
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
warmweer
Jr. Extension Validator
Posts: 11274
Joined: Fri Jul 04, 2003 6:34 am
Location: Van Allen Bel ... gium
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by warmweer »

open-your-eyes wrote: Mon Feb 19, 2018 3:55 pm I can't figure out how to comment out search tables wich I do not need anyway. :(
Help! Please!!!
I'll put it bluntly.
If you don't know how to avoid having to work on those search tables: I suggest you don't mess with the database at all. (repeat hint: you do not need to do anything with the search tables except reduce them to a minimal state = empty)
For the rest you do not need to fool around with the phpBB2 database at all.
Upgrading will handle that automatically (with procedures which have been tested and retested)
Be advised that if you persist in trying to import your 2.x database into a 3.1.x database and then encounter problems, the search for a solution will be a lot more difficult since very few users (even Support Team) will have experience with that.
Spelling is freeware, which means you can use it for free.
On the other hand, it is not open source, which means you cannot change it or publish it in a modified form.


Time flies like an arrow, but fruit flies like a banana.
User avatar
open-your-eyes
Registered User
Posts: 94
Joined: Mon Jul 31, 2017 8:20 am
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by open-your-eyes »

If I do not import the phpBB2 database, then what I am converting? I don't get it. I repeat: I do not have the forum online. I am trying to install it using XAMPP on my computer.
And another thing. I did some testing and it seems romanian characters (ăîşţâ) may get messed up on the conversion. So I may need to first update from 2.0.22 to 2.0.23, then to 3.0.14. And only after that to 3.1.12.
Thanks.
User avatar
KevC
Support Team Member
Support Team Member
Posts: 72375
Joined: Fri Jun 04, 2004 10:44 am
Location: Oxford, UK
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by KevC »

You can get 2.0.x from sourceforge and install it. Put the 2x database in to that. Then run the proper conversion.
-:|:- Support Request Template -:|:-
Image
"Step up to red alert. Sir, are you absolutely sure? It does mean changing the bulb"
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by 3Di »

Create an empty folder with only the phpBB2's config.php file (the connector) and bind that folder to a DB in which you previouly imported the phpBB2 old DB.

You don't need a running phpBB2, that's the trick.

Now you have
www
--- phpBB2
--- phpBB3
And you could run the conversion.
KevC wrote: Mon Feb 19, 2018 4:50 pm You can get 2.0.x from sourceforge and install it. Put the 2x database in to that. Then run the proper conversion.
it's also available at github, which is better, but the OP doesn't need a running BB2.
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
KevC
Support Team Member
Support Team Member
Posts: 72375
Joined: Fri Jun 04, 2004 10:44 am
Location: Oxford, UK
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by KevC »

The config.php file certainly has to be correct though and it's just as easy to do that from a working installation than to edit the file to fit.
-:|:- Support Request Template -:|:-
Image
"Step up to red alert. Sir, are you absolutely sure? It does mean changing the bulb"
User avatar
open-your-eyes
Registered User
Posts: 94
Joined: Mon Jul 31, 2017 8:20 am
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by open-your-eyes »

3Di wrote: Mon Feb 19, 2018 4:55 pm Create an empty folder with only the phpBB2's config.php file (the connector) and bind that folder to a DB in which you previouly imported the phpBB2 old DB.
I can not import it. I get the error from my first post. That's the thing. I know how to convert. I did it before with another board.
So my question remains: How to comment out all instances of INSERT INTO f762dce_search_wordlist? Is the only way to get rid of errors.
Thanks.
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by 3Di »

KevC wrote: Mon Feb 19, 2018 4:57 pm The config.php file certainly has to be correct though and it's just as easy to do that from a working installation than to edit the file to fit.
It's faster to rebuild a config.php file than install a bb2 which doesn't run on certain PHP/DB versions (obsolete and difficult to find also for a local stack).

If the OP doesn't have the old files backup, there is no need to try and resurrect something un-usefull (attachments aren't there etc.. etc..)

The easy and functional way is what I posted, no need IMHO to potentially load the OP of avoidable stuffs. :)
open-your-eyes wrote: Mon Feb 19, 2018 5:00 pm
3Di wrote: Mon Feb 19, 2018 4:55 pm Create an empty folder with only the phpBB2's config.php file (the connector) and bind that folder to a DB in which you previouly imported the phpBB2 old DB.
I can not import it. I get the error from my first post. That's the thing. I know how to convert. I did it before with another board.
So my question remains: How to comment out all instances of INSERT INTO f762dce_search_wordlist? Is the only way to get rid of errors.
Thanks.
No need to post in big-bolded letters, please. I know what I wrote... ;)

You may want to don't import (get rid of the data related, just the data though) those *_search tables, those will be rebuild later on, when you are in BB3, once converted.
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
warmweer
Jr. Extension Validator
Posts: 11274
Joined: Fri Jul 04, 2003 6:34 am
Location: Van Allen Bel ... gium
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by warmweer »

open-your-eyes wrote: Mon Feb 19, 2018 4:48 pm If I do not import the phpBB2 database, then what I am converting? I don't get it. I repeat: I do not have the forum online. I am trying to install it using XAMPP on my computer.
And another thing. I did some testing and it seems romanian characters (ăîşţâ) may get messed up on the conversion. So I may need to first update from 2.0.22 to 2.0.23, then to 3.0.14. And only after that to 3.1.12.
Thanks.
That's what I said in the first place: it's an extra step but a simple step to upgrade to 3.0.14 instead of going to 3.1 directly (or 3.2).
Coming for the 3.0.14 files:
During the conversion, the search index is not created or transferred. This means after conversion you are not able to find any matches if you want to search for something. We recommend you rebuild your search index within Administration Control Panel -> Maintenance -> Database -> Search Index.

The only importing of the phpBB2 database you need is to import your phpBB2 database backup into a database so that it can be used for the conversion (I actually thought you wouldn't even need the phpbb2 files but from the instructions it seems you do need the files but I doubt that - a config file should do the trick).
So the steps are:
1. get the phpbb2more or less installed (on localhost -Xampp) (empty the search tables)
2. update to the latest phpBB 2 (2.0.22?)
3. upgrade to 3.0.14
4. upgrade to 3.1.12 (for this step support will be plentiful on the forum)

I upgraded from 3.0.14 to 3.2.1 directly, and also via 3.1.11 - both upgrades went flawlessly.
3.2.2 has a few problems (which can be solved but considering the large upgrade you are planning I would not go to 3.2.2 immediately but only after getting a working version of 3.2.1
Success!
Last edited by warmweer on Mon Feb 19, 2018 5:13 pm, edited 1 time in total.
Spelling is freeware, which means you can use it for free.
On the other hand, it is not open source, which means you cannot change it or publish it in a modified form.


Time flies like an arrow, but fruit flies like a banana.
User avatar
3Di
I've Been Banned!
Posts: 17538
Joined: Mon Apr 04, 2005 11:09 pm
Location: I'm with Ukraine 🇺🇦
Name: Marco
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by 3Di »

warmweer wrote: Mon Feb 19, 2018 5:11 pm a config file should do the trick
viewtopic.php?p=14942521#p14942521
🆓 Free support for our extensions also provided here: phpBB Studio
🚀 Looking for a specific feature or alternative option? We will rock you!
Please PM me only to request paid works. Thx. Buy me a coffee -> Image
My development's activity º PhpStorm's proud user º Extensions, Scripts, MOD porting, Update/Upgrades
User avatar
warmweer
Jr. Extension Validator
Posts: 11274
Joined: Fri Jul 04, 2003 6:34 am
Location: Van Allen Bel ... gium
Contact:

Re: Upgrade from 2.0.22 to 3.1.12

Post by warmweer »

3Di wrote: Mon Feb 19, 2018 5:13 pm
warmweer wrote: Mon Feb 19, 2018 5:11 pm a config file should do the trick
viewtopic.php?p=14942521#p14942521
OK, but by the time I had finished writing my post you and KevC had already posted and as long as there was nothing conflicting in my post I wasn't going to edit it and possibly create confusion).
Spelling is freeware, which means you can use it for free.
On the other hand, it is not open source, which means you cannot change it or publish it in a modified form.


Time flies like an arrow, but fruit flies like a banana.
Locked

Return to “[3.1.x] Support Forum”