R
R
Reyatsu2018-01-25 12:10:23
ORM
Reyatsu, 2018-01-25 12:10:23

Why does RedBeanPhp's R::find method only find one entry?

Hello.
Maybe someone knows why RedBeanPhp returns only 1 row with such a request, although it should have 64.
$test = R::find( 'nametable' , '"id" = ?' , array($id) );
Now we have to use R::getAll to display the array, and then turn it into bins.
Thanks in advance.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrew4ever, 2018-06-22
@Andrew4ever

Hello.
The query should most likely be: $test = R::find( 'nametable' , `id` = ?' , array($id) );
The difference is in parentheses at id . Column names should be written in brackets ` col_name ` (key "e"), not in " col_name " or ' col_name '

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question