When querying data associated with two tables, the ranking will be affected by the paging page. Ranking will only be performed on the current page. How to solve this problem?
When querying data associated with two tables, the ranking will be affected by the paging page. Ranking will only be performed on the current page. How to solve this problem?
The total_bean field is added to the oc_member table and updated at any time.
Create a view. Since the SQL statement is complex and TP does not support it well, the complex SQL is made into a view, simplifying the SQL statement executed in TP, and then querying the view in TP to obtain the results
$Model=D("BlogView" );
$Model->where($where)->page($page,$end)->select();