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

[BUG] Filter does not work properly when entering double quotation marks (") #229

Open
radmorecameron opened this issue Dec 14, 2022 · 4 comments

Comments

@radmorecameron
Copy link

ISSUE COPIED FROM wet-boew/wet-boew#9497

Describe the bug
When trying to filter using quotation marks, the table does not get properly filtered.

To Reproduce
Steps to reproduce the behavior:

  1. Go to datatables.net example table
  2. Type quotation marks " into the filter textbox
  3. See error, table won't change until 4 double quotations are entered

image

Expected behavior
Rows should disappear when they don't have quotation marks.

Additional information (optional)

Adding a fourth quotation mark will get it to behave as if there was one quotation mark (hard to show as none of the rows in the example here had quotation marks)
image

Desktop/Smartphone (please complete the following information)

  • OS or Device: Windows 10
  • Browser: Edge
  • Version:108.0.1462.46 (Official build) (64-bit)
@AllanJard
Copy link
Contributor

Thank you for the report - agreed, there is something wrong in the handling of the quotes for an exact match string. I'll look into that for the next release.

@wewhite
Copy link

wewhite commented Dec 19, 2022

"this is a limitation of smart searching due to the use of double quotes to do an exact match. Unfortunately the only way around that is to disable the smart search."
https://datatables.net/forums/discussion/26785/search-filter-with-a-double-quote-in-the-string#Comment_73006

@AllanJard
Copy link
Contributor

That is the case for a single double quote yes. But I'm not convinced that the behaviour you are seeing for four double quotes is correct. That said - it will be fairly nuanced due to the exact matching from the double quotes.

@francescodisciascio
Copy link

francescodisciascio commented Aug 9, 2023

A similar issue happens with comma and slash: if you put a comma or a slash in the filter textbox, data does not change. A second comma or slash is needed to see the data changing.

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

No branches or pull requests

4 participants