Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SQL queries to update Piwik to version 1.8.4 are shown with comments therefore breaking them #3386

Closed
anonymous-matomo-user opened this issue Sep 18, 2012 · 1 comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Milestone

Comments

@anonymous-matomo-user
Copy link

Hi,

when updating my Piwik installation, I take the SQL queries that Piwik shows and execute them manually in my SQL client to have better control over it.

Normally this works fine, but with this version there were comments in those queries that broke the query:

INSERT INTO piwik_log_action_duplicates ( SELECT action.idaction AS before, canonical.idaction AS after FROM ( SELECT name, hash, MIN(idaction) AS idaction FROM piwik_log_action AS action_canonical_base WHERE type = 1 AND url_prefix IS NOT NULL GROUP BY name, hash # only grouping by name would be case-insensitive HAVING COUNT(idaction) > 1 ) AS canonical LEFT JOIN piwik_log_action AS action ON (action.type = 1 AND canonical.hash = action.hash) # use index (type, hash) AND canonical.name = action.name AND canonical.idaction != action.idaction ); ;

See the two # parts. As the website states that one should continue executing the other queries if some query might fail, I executed all of them at once. Fortunately, nothing happened in this case, but in general, this is quite critical.

In addition, there are two semi-colons at the end, leading to empty queries and therefore to messages/warnings in my client.

Lars

@mattab
Copy link
Member

mattab commented Sep 19, 2012

Thanks for the report, fixed in [7017]

@anonymous-matomo-user anonymous-matomo-user added this to the 1.9 -- Piwik 1.9 milestone Jul 8, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Projects
None yet
Development

No branches or pull requests

2 participants