Post by OpenCode » Wed Jun 20, 2018 5:23 am

Hi Guys!
maybe is just me but when we upgrade our OC from 1.5.6.4 to the new 3.0.2.0 everything was upgraded almost perfect,
Products, categories, information, and all data was updated the only exception is the products (formerly know as url_alias (SEO Keyword),
this table was not converted to the new seo_ url, all the information still in the old table the new table `seo_url` is empty.
do anyone knows on how to do it manually by running a SQL query directly via phpadmin.
or other option besides doing it manually - any ideas?

Thank you in advance guys!

New member

Posts

Joined
Fri Jun 07, 2013 9:31 am

Post by IP_CAM » Thu Jun 21, 2018 2:56 am

everything was upgraded almost perfect
Well, you possibly feel this way :D
But since you did not mention, in detail, on how you 'upgraded', and what you
upgraded, nobody probably really believes, that your thing will ever work again as
planned. But so, it's of no use, to bother about, just to start another discussion on
this, this place is already full of it.

But please, don't take it personal, it's just an information, since most Upgraders
forget, that 99.99 percent of all OC Users don't use a strictly default Version OC,
but one, in some ways Extension-enhanced and/or modified. With the consequence,
that NO upgrade can work, as planned, in such setups. But that's not OpenCart's
fault, it's, at best, just poor or non-existing Communication, adding to a lot of
problemes, by a lot of OC Users, eager, to mock up their existing System,
with incompatible Parts ... :crazy: like uploading Win10 Drivers and DLL's onto an XP!

Good Luck! ;)
Ernie

For Sale: Top URL's, including an OpenCart V-Pro Shop!
A wide range of matching Designs can be seen here: http://www.opencart.li
For Information on URL's offered, please contact me at: jti@jacob.ch
Hundreds of Mods in 380+ Repositories for OC v.1.5.x - v.2.3.x
to be found on my Github Site: https://github.com/IP-CAM
Image


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland

Post by OpenCode » Fri Jun 22, 2018 4:47 am

IP_CAM wrote:
Thu Jun 21, 2018 2:56 am
everything was upgraded almost perfect
Well, you possibly feel this way :D
But since you did not mention, in detail, on how you 'upgraded', and what you
upgraded, nobody probably really believes, that your thing will ever work again as
planned. But so, it's of no use, to bother about, just to start another discussion on
this, this place is already full of it.

But please, don't take it personal, it's just an information, since most Upgraders
forget, that 99.99 percent of all OC Users don't use a strictly default Version OC,
but one, in some ways Extension-enhanced and/or modified. With the consequence,
that NO upgrade can work, as planned, in such setups. But that's not OpenCart's
fault, it's, at best, just poor or non-existing Communication, adding to a lot of
problemes, by a lot of OC Users, eager, to mock up their existing System,
with incompatible Parts ... :crazy: like uploading Win10 Drivers and DLL's onto an XP!

Good Luck! ;)
Ernie
Upgraded by following the instructions on the file name upgrade.txt that can be found here https://github.com/opencart/opencart/bl ... pgrade.txt

upgraded from OpenCart V1.5.6.4 x TO 3.0.2.0, follow the instructions in the upgrade.txt
but I think they forgot transforming the url_alias table to the new seo_url table, I think DUMPING the old table AND CREATE the new TABLE should
happen in the upgrade don't you think?

the old table

Code: Select all

CREATE TABLE IF NOT EXISTS `url_alias` (
  `url_alias_id` int(11) NOT NULL,
  `query` varchar(255) NOT NULL,
  `keyword` varchar(255) NOT NULL
) ENGINE=MyISAM AUTO_INCREMENT=DEFAULT CHARSET=utf8;
to the new table

Code: Select all

CREATE TABLE IF NOT EXISTS `seo_url` (
  `seo_url_id` int(11) NOT NULL,
  `store_id` int(11) NOT NULL,
  `language_id` int(11) NOT NULL,
  `query` varchar(255) NOT NULL,
  `keyword` varchar(255) NOT NULL
) ENGINE=MyISAM AUTO_INCREMENT=DEFAULT CHARSET=utf8;
and since the old URL table still in the DB my question is how can I get the information out and move to the new SEO_URL table, adding the new names fields.
I when and check the upgrade script made by Q to upgrade the v2 and this table is not reformated for the upgrade either, so my guessing is either nobody has noticed or is just left out, I think products URL are important as well the rest of the data upgraded, don't you think?

anyways I'm with Opencart since V.0 ( when qphoria chromecart I think that's the name close his Idea and move it over here to OC) all throughout the changes, I also see that Daniel and other moderator has lost control of the forum, as well deleting old good tips for older versions, so they can sell their module base on the free ideas of others.

anyways all I need is the query to runed directly in phpadmin to get the data updated or drop the new table and re-created with the data from url_alias that's old.

Thank you for taking the time of reading my post-Ernie.

PS: I'm Apple user but I got your point

New member

Posts

Joined
Fri Jun 07, 2013 9:31 am

Post by kestas » Fri Jun 22, 2018 7:23 am

You can try do it in your phpMyAdmin.

IMPORTANT!!! Before you try, please make backup all of your tables.
If you have both oc_seo_url and oc_url_alias (old and new) tables and new table is empty DROP new table.
Open your DB in phpMyAdmin click tab SQL

Make sure what prefix of your tables if not "oc" change it in code below.
first add:

Code: Select all

ALTER TABLE `oc_url_alias` RENAME TO `oc_seo_url`
click GO

next click tab SQL add:

Code: Select all

ALTER TABLE `oc_seo_url`
CHANGE COLUMN  `url_alias_id`  seo_url_id int(11) NOT NULL
click GO

next click tab SQL add:

Code: Select all

ALTER TABLE `oc_seo_url`
ADD COLUMN  `store_id` int(11) NOT NULL
AFTER       `seo_url_id`
click GO

next click tab SQL add:

Code: Select all

ALTER TABLE `oc_seo_url`
ADD COLUMN  `language_id` int(11) NOT NULL
AFTER       `store_id`
click GO
IMPORTANT!!! Before you try, please make backup all of your tables.

Custom OpenCart modules and solutions. Just PM me... Extensions you can find here and here


Active Member

Posts

Joined
Tue Oct 12, 2010 2:23 am

Post by OpenCode » Sat Jun 23, 2018 1:16 am

kestas wrote:
Fri Jun 22, 2018 7:23 am
You can try do it in your phpMyAdmin.

IMPORTANT!!! Before you try, please make backup all of your tables.
If you have both oc_seo_url and oc_url_alias (old and new) tables and new table is empty DROP new table.
Open your DB in phpMyAdmin click tab SQL

Make sure what prefix of your tables if not "oc" change it in code below.
first add:

Code: Select all

ALTER TABLE `oc_url_alias` RENAME TO `oc_seo_url`
click GO

next click tab SQL add:

Code: Select all

ALTER TABLE `oc_seo_url`
CHANGE COLUMN  `url_alias_id`  seo_url_id int(11) NOT NULL
click GO

next click tab SQL add:

Code: Select all

ALTER TABLE `oc_seo_url`
ADD COLUMN  `store_id` int(11) NOT NULL
AFTER       `seo_url_id`
click GO

next click tab SQL add:

Code: Select all

ALTER TABLE `oc_seo_url`
ADD COLUMN  `language_id` int(11) NOT NULL
AFTER       `store_id`
click GO
IMPORTANT!!! Before you try, please make backup all of your tables.
@ kestas, Thank you very Much! that work like a charm saves us a lot of time...

the only thing we did after running all the SQL queries, was run the following since the language_id has a value of 1.

Code: Select all

UPDATE `oc_seo_url` SET `language_id` = '1';
or can also be done (I guess) as follow if you only have one language in your store.

Code: Select all

ALTER TABLE `oc_seo_url`
ADD COLUMN  `language_id` int(11) NOT NULL DEFAULT '1'
AFTER       `store_id`
if anyone has the same problem we were having, kestas solution works like charm just make sure, "IMPORTANT!!! Before you try, please make backup all of your tables." as KESTAS suggested.

The help and solution kestas has post here it remaimgs me old times OpenCart's when the v1.4 was out everbody pitch in for the "bugs" and solutions.

I think help still available here if everyone using the forum to find the solution for their issues with their OC store, pitch in with donations for the developer, that offer the solution to the problem.

kestas, I like to buy you a cup of coffee. please let me know how to do that.

Thank You for your help.

New member

Posts

Joined
Fri Jun 07, 2013 9:31 am

Post by kestas » Sat Jun 23, 2018 9:59 pm

OpenCode wrote:
Sat Jun 23, 2018 1:16 am
kestas, I like to buy you a cup of coffee. please let me know how to do that.
Nice. I'm very happy if it helped for you.
Regarding the coffee I can't.... refuse your suggestion to drink a cup of coffee.
If you still wish to make me more happy you can make it via paypal: kestas@vigintos.com :crazy: ::)

Cheers

Custom OpenCart modules and solutions. Just PM me... Extensions you can find here and here


Active Member

Posts

Joined
Tue Oct 12, 2010 2:23 am

Post by OpenCode » Mon Jun 25, 2018 1:25 am

I just did
To kestas,
For your cup of coffee.
For helping me on the DB solution
From OpenCode.
Thank you
I hope OC Forum moderator don't delete it can help others.

Thank You

New member

Posts

Joined
Fri Jun 07, 2013 9:31 am
Who is online

Users browsing this forum: No registered users and 5 guests