TablePlus-Windows icon indicating copy to clipboard operation
TablePlus-Windows copied to clipboard

MySQL BETWEEN on date field syntax error

Open rwhirn opened this issue 5 years ago • 4 comments

  1. Which driver are you using and version of it (Ex: PostgreSQL 10.0): MySQL 5.7.17

  2. Which TablePlus build number are you using (the number on the welcome screen, Ex: build 81): 130

  3. The steps to reproduce this issue: on a date field select: BETWEEN type dates: 2020-06-15 AND 2020-06-17 get bad syntax: BETWEEN "2020-06-15 AND 2020-06-17" type dates: '2020-06-15' AND '2020-06-17' get bad syntax: BETWEEN "'2020-06-15' AND '2020-06-17'" type dates: CAST('2020-06-15' AS DATE) AND CAST('2020-06-17' AS DATE) get bad syntax: BETWEEN "CAST('2020-06-15' AS DATE) AND CAST('2020-06-17' AS DATE)"

Why do we have to type the AND anyway? It would be nice if BETWEEN would allow two entry fields and not require typing the AND and/or trying to figure out how to type, quotes or not, etc.

rwhirn avatar Jun 19 '20 17:06 rwhirn

@huyphams No time to look at this yet?

rwhirn avatar Jun 24 '20 16:06 rwhirn

Hi @rwhirn please try this patch: https://www.dropbox.com/s/eqztxlh2bai0lyd/TablePlusUpdate.exe?dl=0 Thanks!

huyphams avatar Jun 25 '20 04:06 huyphams

All fixed! Thanks.

rwhirn avatar Jun 25 '20 15:06 rwhirn

This issue came back somewhere along the way, not sure how long ago, but I think its been awhile. Build: 290 MySQL 5.7.44 image

rwhirn avatar Jan 14 '25 18:01 rwhirn