queryStream method

Stream<PostgreSQLResultRow> queryStream(
  1. String fmtString, {
  2. dynamic substitutionValues,
  3. PlaceholderIdentifier placeholderIdentifier = PlaceholderIdentifier.atSign,
  4. int fetchSize = 1000,
  5. int? timeoutInSeconds,
})

Implementation

Stream<PostgreSQLResultRow> queryStream(
  String fmtString, {
  dynamic substitutionValues,
  PlaceholderIdentifier placeholderIdentifier = PlaceholderIdentifier.atSign,
  int fetchSize = 1000,
  int? timeoutInSeconds,
}) {
  final self = this;
  if (self is _PostgreSQLExecutionContextMixin) {
    return self.queryStream(fmtString,
        substitutionValues: substitutionValues,
        placeholderIdentifier: placeholderIdentifier,
        fetchSize: fetchSize,
        timeoutInSeconds: timeoutInSeconds);
  }
  if (self is PostgreSQLPool) {
    return self.queryStream(fmtString,
        substitutionValues: substitutionValues,
        placeholderIdentifier: placeholderIdentifier,
        fetchSize: fetchSize,
        timeoutInSeconds: timeoutInSeconds);
  }
  throw UnsupportedError('queryStream is only supported by '
      'PostgreSQLConnection, its transactions and PostgreSQLPool, not by '
      '$runtimeType.');
}