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

Fix #17635 - Semicolon repeatedly suffixed onto SQL if query ends in comment #18264

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

LakshayaTohan
Copy link

Description

Added check for addition of semicolon only when it is missing while editing and/or running an SQL query.

Fixes #17635

Before submitting pull request, please review the following checklist:

  • Make sure you have read our CONTRIBUTING.md document.
  • Make sure you are making a pull request against the correct branch. For example, for bug fixes in a released version use the corresponding QA branch and for new features use the master branch. If you have a doubt, you can ask as a comment in the bug report or on the mailing list.
  • Every commit has proper Signed-off-by line as described in our DCO. This ensures that the work you're submitting is your own creation.
  • Every commit has a descriptive commit message.
  • Every commit is needed on its own, if you have just minor fixes to previous commits, you can squash them.
  • Any new functionality is covered by tests.

@williamdes williamdes changed the title Fix for ChrisHSandN/phpmyadmin#17635 Fix #17635 - Semicolon repeatedly suffixed onto SQL if query ends in comment Mar 16, 2023
@LakshayaTohan LakshayaTohan force-pushed the fix-issue-17635-semicolon-repeatedly-suffixed branch from 1e28bf1 to 0f47d83 Compare March 16, 2023 12:33
LakshayaTohan and others added 3 commits May 6, 2023 12:46
…SQL query

Signed-off-by: Lakshaya Tohan <lakshaya.tohan@gmail.com>
… the query

Signed-off-by: William Desportes <williamdes@wdes.fr>
Signed-off-by: William Desportes <williamdes@wdes.fr>
@williamdes williamdes force-pushed the fix-issue-17635-semicolon-repeatedly-suffixed branch from 0f47d83 to 9b30512 Compare May 6, 2023 21:23
@codecov
Copy link

codecov bot commented May 6, 2023

Codecov Report

Patch coverage: 88.88% and project coverage change: +0.02 🎉

Comparison is base (3156c39) 54.95% compared to head (9b30512) 54.97%.

Additional details and impacted files
@@             Coverage Diff              @@
##             master   #18264      +/-   ##
============================================
+ Coverage     54.95%   54.97%   +0.02%     
- Complexity    16428    16434       +6     
============================================
  Files           631      631              
  Lines         64544    64550       +6     
============================================
+ Hits          35467    35487      +20     
+ Misses        29077    29063      -14     
Flag Coverage Δ
dbase-extension 54.97% <88.88%> (+0.03%) ⬆️
recode-extension 54.92% <88.88%> (+<0.01%) ⬆️
unit-8.1-ubuntu-latest 54.92% <88.88%> (+<0.01%) ⬆️
unit-8.2-ubuntu-latest 54.92% <88.88%> (+<0.01%) ⬆️
unit-nightly-ubuntu-latest 54.92% <88.88%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
libraries/classes/Import.php 26.70% <88.88%> (+1.09%) ⬆️

... and 1 file with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@williamdes williamdes added this to the 6.0.0 milestone May 7, 2023
@williamdes
Copy link
Member

@kamil-tekiela You did some refactoring to this code, how can this be merged without needing to use that very costy str_contains function ?

@kamil-tekiela
Copy link
Contributor

str_contains is not very costly. I guess this just needs a rebase.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Semicolon repeatedly suffixed onto SQL if query ends in comment
3 participants