activerecord yii2 select with limit(start,end) not working

To select records with a limit using Yii2's ActiveRecord, you can use the limit() method. Here's an example:

$query = YourModel::find()->limit($limit)->offset($offset)->all();

Replace YourModel with the name of your ActiveRecord model. $limit represents the number of records you want to retrieve, and $offset represents the starting point of the records.

Make sure to replace $limit and $offset with the appropriate values in your code.

If you're still experiencing issues with the limit() method, please provide more details about the problem you're facing so that I can assist you further.