execMapList method

List<Map<String, dynamic>> execMapList(
  1. String query
)

Excecute a sql query return data as list of Map and dispose (Release Resources)

Implementation

List<Map<String, dynamic>> execMapList(String query) {
  PqResult? result;
  try {
    result = exec(query);
    final data = result.asMapList();
    return data;
  } catch (e) {
    rethrow;
  } finally {
    result?.dispose();
  }
}