Type casting in PostgreSQL with updateBatch() |
(01-16-2024, 09:27 PM)kenjis Wrote: I sent a PR: https://github.com/codeigniter4/CodeIgniter4/pull/8426 Man I couldn't be any more happier. Thank you so-much. You made my day. You are the best. Love you ma man. (y)
Tests and reviews are welcome.
I hope individuals with strong technical skills can offer assistance. I wish I possessed such skills to contribute. I attempted to rectify this after a few hours of struggling, but unfortunately, I failed. Every value is gets enclosed in quotes. I spent several days trying to comprehend how things interconnect, but I couldn't figure it out.
I want to convey that I genuinely desire to actively contribute to CI4, but I'm not at that level yet. I highly appreciate what you all are doing here. I eat, live, and take care of my family because of you guys. Thank you so much ![]() (01-01-2024, 01:19 PM)MrWhite Wrote: I have this issue. i dunno what to do. (01-16-2024, 09:48 PM)kenjis Wrote: Tests and reviews are welcome. I reviewed its fine but it has to be documented. I will give it a try on its test
The quick and easy fix for this is to use RawSql as well as casting your php values:
Code: $data = [ https://codeigniter.com/user_guide/datab...tml#rawsql Another things to have a look at is: https://www.postgresql.org/docs/current/...ecast.html (01-17-2024, 08:19 PM)kenjis Wrote: Added the docs: https://github.com/codeigniter4/CodeIgniter4/pull/8426Big thanks ![]() (01-19-2024, 03:25 PM)sclubricants Wrote: The quick and easy fix for this is to use RawSql as well as casting your php values: Yeah! nice trick.
There are four options now. Any opinion? or another solution?
See https://github.com/codeigniter4/CodeIgni...1901901019
I sent another PR. This seems better.
fix: [Postgre] QueryBuilder::updateBatch() does not work (No API change) by kenjis · Pull Request #8439 · codeigniter4/CodeIgniter4 https://github.com/codeigniter4/CodeIgniter4/pull/8439 |
Welcome Guest, Not a member yet? Register Sign In |