Previous Page
countPages()

Solar_Sql_Model
countPagesRelated()

Next Page
delete()

countPagesRelated()

public array countPagesRelated ( Solar_Sql_Model_Record $record, string $name, array $params default NULL )

Counts the number of records in a related model for a given record.

Parameters

  • (Solar_Sql_Model_Record) $record: The record to count related pages for.
  • (string) $name: The name of the relationship to count pages for.
  • (array) $params: Parameters for the related SELECT; honors keys for 'where', 'having', 'group', and 'paging'.

Returns

  • (array) An array with keys 'count' (the count of records) and 'pages' (the number of pages of records).

Description

Counts the number of records in a related model for a given record.