# |
Aug 23rd 2019, 09:22 |
conehead |
just use `debug` around it |
# |
Aug 23rd 2019, 09:20 |
slackebot2 |
'fields' => array( 'name', 'email', ) )); ``` |
# |
Aug 23rd 2019, 09:20 |
chan |
how to see log of sql query in cakephp for ``` $this->Master->find('all', array( 'conditions' => array( 'AND' => array('Master.client_id' => $client_id), 'OR' => array( array('Master.selected_main_group_id' => null), array('Master.selected_main_group_id' => 88), ), ), |
# |
Aug 23rd 2019, 08:31 |
val |
Hi, would it be possible to have a standalone 3.x shell classes library like standalone ORM https://github.com/cakephp/orm? |
# |
Aug 23rd 2019, 08:15 |
conehead |
I had/have one table that holds many entities which are linked to one Entity each. Lets say `Documents` and `Users` and the table `Statuses` had the fields `id, foreign_id, model, someData`. So you could link a `Status` with Documents and Users. If Documents use uuids but Users use ids, there is going to be a massive performance drain (timing out for me) when you try to access the linked data |
# |
Aug 23rd 2019, 08:11 |
mehov |
@conehead thanks for the tip. what do you mean "do not mix ids and uuids" - as in don't use them in the same query, or maybe same database? |
# |
Aug 23rd 2019, 08:08 |
lubos |
How do I paginate union results? I mean is it possible somehow to use `Paginator` with `Cake\Database\Query`? |
# |
Aug 23rd 2019, 07:55 |
conehead |
With all of your help ;) But still find it a little strange |
# |
Aug 23rd 2019, 07:54 |
neon1024 |
@conehead Good job figuring it out :thumbsup: |
# |
Aug 23rd 2019, 07:47 |
conehead |
alex, neon and admad...and everyone else who helped me yesterday: I finally found out...do not mix uuids and ids...ever. This was the only reason everything slowed down a gazillion times |
# |
Aug 23rd 2019, 07:47 |
lubos |
`disableHydration` is what I was looking for :slightly_smiling_face: |
# |
Aug 23rd 2019, 07:45 |
lubos |
I am trying to do SQL union, that's why this would be useful |
# |
Aug 23rd 2019, 07:44 |
lubos |
Morning, is it possible to adjust query to not have prefix in results, e.g. `$this->Posts->find()` will have `'Post' => [..]` in result set and I would like to have just `[..]` |
# |
Aug 23rd 2019, 07:38 |
chan |
handwritten query data count is 4. but cakephp 2 find condition data count is 3. |
# |
Aug 23rd 2019, 07:36 |
alexdd55976 |
whats the difference? |
# |
Aug 23rd 2019, 07:36 |
alexdd55976 |
where does the data differ from query to find()? |
# |
Aug 23rd 2019, 07:35 |
chan |
@alexdd55976 i run on this query with mysql navigate |
# |
Aug 23rd 2019, 07:35 |
alexdd55976 |
@chan the query on top is the generated query or is it handwritten? |
# |
Aug 23rd 2019, 07:24 |
chan |
how to write with model find condition, query is ok, but cakephp 2 model find all wrong. ``` select id, username, main_group_id, client_id, selected_main_group_id, role_id from masters where client_id = 15 and (selected_main_group_id is null OR selected_main_group_id =88); ``` |
# |
Aug 23rd 2019, 07:15 |
neon1024 |
Morning everyone! Happy Friday :tada: |
# |
Aug 23rd 2019, 07:15 |
alexdd55976 |
agreed |
# |
Aug 23rd 2019, 07:14 |
conehead |
Maybe used a different field name? Or you got it fixed now? It is quiet hard to understand where your problem is |
# |
Aug 23rd 2019, 07:11 |
Albert |
so it always turn out that my password is wrong since my pw in the db is hash |
# |
Aug 23rd 2019, 07:10 |
Albert |
yeah. i found out that my password is not hashing when im trying to log |
# |
Aug 23rd 2019, 07:10 |
conehead |
The problem is probably not in that line of code |
# |
Aug 23rd 2019, 07:10 |
Albert |
i read many forums |
# |
Aug 23rd 2019, 07:10 |
Albert |
aside from that problem since everything is fine |
# |
Aug 23rd 2019, 07:09 |
Albert |
i watched a video using 3.4 and it went fine |
# |
Aug 23rd 2019, 07:09 |
Albert |
i'm using 3.8 |
# |
Aug 23rd 2019, 07:09 |
conehead |
CakePHP version? |
# |
Aug 23rd 2019, 07:09 |
Albert |
auth |
# |
Aug 23rd 2019, 07:09 |
Albert |
that code seems to be the problem. |
# |
Aug 23rd 2019, 07:08 |
Albert |
I'm having problems when logging in |
# |
Aug 23rd 2019, 07:08 |
Albert |
$user= $this->Auth->identify(); |
# |
Aug 23rd 2019, 07:01 |
conehead |
Depends. If you can let us know where your problem is |
# |
Aug 23rd 2019, 06:56 |
Albert |
can you help me? |
# |
Aug 23rd 2019, 06:51 |
alexdd55976 |
? |
# |
Aug 23rd 2019, 06:43 |
Albert |
rrect Login'); |
# |
Aug 23rd 2019, 06:43 |
Albert |
public function login(){ |
# |
Aug 23rd 2019, 06:43 |
alexdd55976 |
hi |
# |
Aug 23rd 2019, 03:17 |
admad |
hi |