Skip to content

[5.3] sql postgresql valid json #45395

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

Merged
merged 4 commits into from
May 6, 2025
Merged

[5.3] sql postgresql valid json #45395

merged 4 commits into from
May 6, 2025

Conversation

alikon
Copy link
Contributor

@alikon alikon commented Apr 26, 2025

Pull Request for Issue #45394 .

Summary of Changes

fix json

Testing Instructions

update from 5.2.3 or lower to a current Joomla version with postgresql

Actual result BEFORE applying this Pull Request

invalid json

Expected result AFTER applying this Pull Request

valid json

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

@alikon alikon marked this pull request as ready for review April 26, 2025 08:05
@QuyTon
Copy link
Contributor

QuyTon commented Apr 27, 2025

I have tested this item ✅ successfully on b9ffc52


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45395.

@heelc29
Copy link
Contributor

heelc29 commented Apr 27, 2025

This do not fix already broken sites.

@richard67
Copy link
Member

richard67 commented Apr 27, 2025

This do not fix already broken sites.

Correct.

@alikon Could you add a new update SQL script for PostgreSQL only with the right version and a suitable date, e.g. 5.3.1-2025-04-27.sql, which updates existing records with the wrong value? E.g.:

UPDATE "#__mail_templates"
 SET "params" = '{"tags":["messages","message","date","extension","username"]}'
 WHERE "template_id" = 'com_actionlogs.notification'
 AND "params" = '"tags":["messages","message","date","extension","username"]}';

As we are only checking for the complete "params" string, we can update the complete string without using any JSON functions. IF someone has already edited that mail template, if should fixed so the WHERE clause will not match.

@heelc29
Copy link
Contributor

heelc29 commented Apr 29, 2025

I have tested this item ✅ successfully on b912a2f

Update 4.4.13 to 5.3.0
image

Update 4.4.13/5.3.0 (broken) to this PR
image


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45395.

@richard67
Copy link
Member

I have tested this item ✅ successfully on b912a2f


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45395.

@richard67
Copy link
Member

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/45395.

@joomla-cms-bot joomla-cms-bot added the RTC This Pull Request is Ready To Commit label May 1, 2025
@richard67 richard67 added the bug label May 1, 2025
@laoneo laoneo merged commit ba5d40a into joomla:5.3-dev May 6, 2025
3 checks passed
@joomla-cms-bot joomla-cms-bot removed the RTC This Pull Request is Ready To Commit label May 6, 2025
@laoneo
Copy link
Member

laoneo commented May 6, 2025

Thanks!

@laoneo laoneo added this to the Joomla! 5.3.1 milestone May 6, 2025
@alikon alikon deleted the patch-20 branch May 7, 2025 12:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants