getCount abstract method

  1. @Query.new('''SELECT count(*) FROM product_measure WHERE (0 = :productId or product_id = :productId) and (0 = :currencyId or currency_id = :currencyId) and status = 1''')
Future<int?> getCount(
  1. int productId,
  2. int currencyId
)

Implementation

@Query('''SELECT count(*) FROM product_measure WHERE
     (0 = :productId or product_id = :productId) and
     (0 = :currencyId or currency_id = :currencyId) and status = 1''')
Future<int?> getCount(int productId, int currencyId);