Closed Okipa closed 1 year ago
@devgiu
I tried to reproduce to issue on the V5 (the SQL treatment is bearly the same than V3) and I couldn't write a test that is putting the problem in evidence.
You can see it here : https://github.com/Okipa/laravel-table/pull/130
Could please try to write a test that would highlight the problem ?
I see that you are using Postgres, the tests are running under MySQL and the behavior is fine: could it be possible that the issue is triggered only with postgres when we try to lower date or integer fields ?
I don't use much Postgres, so I would appreciate any help for this.
Sorry, no idea how to do testing, I have only one project with Laravel. Yes, probably issue is only with postgres and not mysql because Postgres forces the need of casting. I solved temporary with a previous version. Issue comes from changes on this commit https://github.com/Okipa/laravel-table/commit/705267ecdc2544ec0e2896f47167fe807efed7b8
@devgiu Did you bumped your version of Postgres recently ?
I found an issue on another package that explains that functions only accept strings since PG 8.4 => https://github.com/thoughtbot/administrate/issues/620
That may be related to your case. I think that I can manage to implement a fix on V5.
Using the previous version will work for you but the search will be an exact search (the case will have to be exactly the same to return results).
No, I chanched nothing, in the server, only on my project. I understand the issue about the case, but I can live with that, but not with the problem, and upgrade ight now to latest versions is probably a pain. It's a project I'm being hired to just add some features or fix some issues and nothing more
@devgiu I created a PR with a potential fix : https://github.com/Okipa/laravel-table/pull/131/files
Could please try to install the package with the 3.1.4
branch ?
To do that, executing composer require "okipa/laravel-table:dev-3.1.4"
should work.
@devgiu I have edited my post above with the correct composer instruction.
I also made a fix: there was a missing opening parenthesis after CAST
.
Please tell me if this is working for you.
@devgiu I have implemented a fix for v5.
I let you tell me if you need this PR to be implemented as well and tagged 3.1.4: https://github.com/Okipa/laravel-table/pull/131
It would be an exceptional implementation on a previous version as I usually don't maintain versions other than the current one (I still may accept contributions).
Thanks, will try ASAP in next days
Discussed in https://github.com/Okipa/laravel-table/discussions/125