Log message #4192689

# At Username Text
# Jul 10th 2019, 13:27 revillosakristianpaol hi
# Jul 10th 2019, 13:26 felix.robaglia Hello, I want to store in the database the id of the last user who modified this row (column name is id_latest_user_update). Do I have an easy way to tell cakePHP : "Everytime you update a field, set id_latest_user_update to current session id" ? Thanks :slightly_smiling_face:
# Jul 10th 2019, 13:23 davorminchorov Hi, Does anyone here know why do I see `File not found.` when I open my app in the browser?
# Jul 10th 2019, 13:14 rajesh @admad we also need immutable finish from msd and jaddu :slightly_smiling_face:
# Jul 10th 2019, 12:36 inoas lorenzo yeah that would be really nice to go the immutable route :)
# Jul 10th 2019, 12:36 admad and our batting after the 3 top is equally shitty
# Jul 10th 2019, 12:34 admad @neon1024 your shitty weather screwed us over :P
# Jul 10th 2019, 12:28 lorenzo sad that the pipe operator never got a voting
# Jul 10th 2019, 12:27 lorenzo no, you need to filter then out with distinct or group by
# Jul 10th 2019, 12:21 inoas thanks for pointing the way without difficult exists/union things
# Jul 10th 2019, 12:19 inoas so I get some true duplicates that I can remove with distinct - there is nothing I can do abou,r ight?
# Jul 10th 2019, 12:18 inoas ok will do the same - a pipe operator would be nice https://wiki.php.net/rfc/pipe-operator
# Jul 10th 2019, 12:13 lorenzo I prefer assigning the variable again
# Jul 10th 2019, 12:12 inoas btw is it good style to write $query = $query->mutatingBuilderMethod() or just $query->mutatingBuilderMethod?
# Jul 10th 2019, 12:10 lorenzo no, the the where() clause needs to be in the parent query
# Jul 10th 2019, 12:10 inoas so not within the closure
# Jul 10th 2019, 12:10 lorenzo `leftJoinWith('TariffsManufacturers.Manufacturers')->where(['OR' => ['Manufacturers.id IS' =>null, $conditions])`
# Jul 10th 2019, 12:10 inoas working on that now - thanks
# Jul 10th 2019, 12:09 lorenzo ionas I think I just wrote the exact code 2 messages ago :slightly_smiling_face:
# Jul 10th 2019, 12:05 inoas lorenzo I got a working reduced case in raw SQL now: https://gist.github.com/inoas/18618c0ad24ec11d27867dd923322a6c - but I am not sure how to best translate that to the orm
# Jul 10th 2019, 11:46 inoas let me try
# Jul 10th 2019, 11:46 inoas now that sounds like I can udnerstand it at least
# Jul 10th 2019, 11:46 lorenzo that is similar to the approach of `notMatching` but you have a bit more control
# Jul 10th 2019, 11:45 lorenzo `leftJoinWith($stuff)->where(['OR' => ['Manufacturers.id IS' =>null, $conditions])`
# Jul 10th 2019, 11:44 lorenzo ionas you can do it with a leftJoinWith
# Jul 10th 2019, 11:38 inoas is there a more transparent way to do it, this seems like venn-diagram double negation by my gut, I am still trying to wrap my head around it
# Jul 10th 2019, 11:36 inoas can I do notInnerJoinWith ;)?
# Jul 10th 2019, 11:36 inoas AND (Manufacturers.id) IS NULL) that seems to be injected
# Jul 10th 2019, 11:35 inoas but I don't understand it entirely
# Jul 10th 2019, 11:33 inoas the test data wasn't good
# Jul 10th 2019, 11:33 inoas lorenzo I think your notMatching works after all
# Jul 10th 2019, 11:29 dereuromark the callback could also need some example and use cases shown.
# Jul 10th 2019, 11:23 inoas lorenzo I am back
# Jul 10th 2019, 11:11 neon1024 Although as that’s wrapped by `get()` perhaps not as pertinent
# Jul 10th 2019, 11:11 neon1024 I can’t see `firstOrFail` either
# Jul 10th 2019, 11:11 ricksaccous for the longest time i didn't know findOrCreate had a callback, lol
# Jul 10th 2019, 11:09 dereuromark Why is findOrCreate not sth found on the book/docs? thats kinda weird, also not on https://book.cakephp.org/3.0/en/orm/retrieving-data-and-resultsets.html itself
# Jul 10th 2019, 10:28 neon1024 What’s happening @admad :cricket_bat_and_ball: :,)
# Jul 10th 2019, 10:19 np Hello https://stackoverflow.com/questions/56967784/cakephp-3-how-to-do-document-useimmutable-method-in-bootstrap-php
# Jul 10th 2019, 09:32 felix.robaglia correct way is $this->Flash->success(__('id {0} has been disabled', $user->id));
# Jul 10th 2019, 09:32 felix.robaglia I found out why it wasn't working, I writed the $user->id outside of the parenthesis.