You are here

function commerce_reset_get_data_count in Commerce Reset 7

Database record count function.

Parameters

string $table_name: Database table name.

string $primary_key: Primary key of the table.

Return value

int Total count of the records.

5 calls to commerce_reset_get_data_count()
commerce_reset_commerce_message_data_count in modules/commerce_reset_commerce_message/commerce_reset_commerce_message.module
Get Commerce Message Count.
commerce_reset_customer_profiles_count in ./commerce_reset.helpers.inc
Return customer profile count.
commerce_reset_order_count in ./commerce_reset.helpers.inc
Return order count.
commerce_reset_products_count in ./commerce_reset.helpers.inc
Return product count.
commerce_reset_transaction_count in ./commerce_reset.helpers.inc
Return payment transaction count.

File

./commerce_reset.helpers.inc, line 95
Contains helper functions for commerce reset.

Code

function commerce_reset_get_data_count($table_name, $primary_key) {
  $data = commerce_reset_get_entity_data($table_name, $primary_key);
  return $data
    ->rowCount();
}