Answer the question
In order to leave comments, you need to log in
How to retrieve records from the database for a specific user(s)?
Hello everyone, how can I display records for a specific user, for example, in a database, table No. 1 stores data with content, and the second table stores data with IDs of users who have access. Relationship - many to many
Table #1
Table #2
Sample code$model = Instances::find()->with('access')->all();
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question