avatar jimijon
jimijon
13 Mar 2015

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 'delimiter ';;' create procedure weblinks_schema_change() begin /* delete colum' at line 1 SQL=delimiter ';;' create procedure weblinks_schema_change() begin /* delete columns if they exist */ if exists(SELECT * FROM information_schema.columns WHERE table_name = '#__weblinks' AND column_name = 'sid') THEN ALTER TABLE mmp_exd_j25_weblinks DROP COLUMN sid;

Package Install: There was an error installing an extension: com_weblinks.zip

avatar jimijon jimijon - open - 13 Mar 2015
avatar bembelimen
bembelimen - comment - 13 Mar 2015

Same error here.

PHP 5.4.16 cgi-fcgi
MySQL 5.6.19

avatar nicksavov
nicksavov - comment - 13 Mar 2015

I tried several different syntaxes, however it doesn't appear that the delimiter works for non-command-line API.

avatar mbabker
mbabker - comment - 13 Mar 2015

So any suggestions on how to run a query to drop a column if it exists without throwing errors? That's exactly what this was trying to get around.

avatar jimijon
jimijon - comment - 13 Mar 2015

maybe change the delimiter ";;" to delimiter //

avatar nicksavov
nicksavov - comment - 13 Mar 2015

That won't work, unfortunately. The "delimiter" command doesn't appear to be allowed at all in this context.

avatar nicksavov
nicksavov - comment - 13 Mar 2015

@mbabker, I'm not seeing a good/easy way to do it

avatar jimijon
jimijon - comment - 13 Mar 2015

maybe separate sql scripts?

avatar mbabker
mbabker - comment - 13 Mar 2015

@mbabker, I'm not seeing a good/easy way to do it

Ya, that was the only way I could find since there isn't a native IF EXISTS format in this case.

@jimijon What do you mean by separate scripts? If the file is in the folder our manifest says to use for update processing, it gets run automatically. If it isn't there, it won't run, but then a user would have to manually get the file's contents and run it via phpMyAdmin or some other resource. And I don't think that's a very viable option either.

avatar jimijon
jimijon - comment - 13 Mar 2015

Well IF EXISTS doesn't work,,, then maybe create a new table, and then insert the data with the columns that are necessary.

avatar bembelimen
bembelimen - comment - 15 Mar 2015

What about a PHP update script?

avatar mbabker
mbabker - comment - 15 Mar 2015

That's an option. We can use our extension update script feature and the JDatabase API to process that part of the SQL update.

avatar flashfs
flashfs - comment - 23 Mar 2015

Same problem here.
Upgraded from 2.5.28 to 3.4.0 and the Weblinks component was not working well. Tried to install the extension package, but this error appears.

avatar mawsInternet
mawsInternet - comment - 23 Mar 2015

I am upgrading from Joomla! 2.5.28 to 3.4.1 and I have encountered the described error. Do I understand correctly that manually performing a Drop on column sid in table ..._weblinks corrects the issue? If not, what all is involved?

I appreciate your help.

avatar zero-24 zero-24 - reference | - 1 Apr 15
avatar zero-24
zero-24 - comment - 1 Apr 2015

Please try this: #30 (package download included)

avatar mawsInternet
mawsInternet - comment - 2 Apr 2015

Thank you zero-24 ... I installed the package and saw a happy Success!
message.

Yours in service,

Keith G.
MAWS Internet Trustee
+1.310.863.9943

On Wed, Apr 1, 2015 at 2:30 PM, zero-24 notifications@github.com wrote:

Please try this: #30
#30 (package download
included)


Reply to this email directly or view it on GitHub
#25 (comment)
.

avatar Bakual
Bakual - comment - 10 Apr 2015

Will be fixed with #30

avatar Bakual Bakual - close - 10 Apr 2015

Add a Comment

Login with GitHub to post a comment