Does FuelPHP 1.x support ON DUPLICATE with the DB Query Builder?
题
I don't see any documentation or core code to specifically address Insert ... On Duplicate update...
So is the only alternative to write a strait DB::query(); call?
解决方案
No, this is not supported by the QB.
Currently the FuelPHP Query Builder has a generic SQL generator, independent of the target platform, so it can generate ANSI SQL only. ON DUPLICATE KEY is MySQL specific.
For version 2.0, the entire Query Builder is being rewritten at the moment to support platform specific SQL dialects. Support for this specific statement is however not on the roadmap.
不隶属于 StackOverflow