whereRaw method

  1. @override
QueryBuilder whereRaw(
  1. String whereRawSql, {
  2. String andOr = 'AND',
  3. Map<String, dynamic>? substitutionValues,
})
override

Example PostgreSQL: whereRaw('b.info ilike @info', andOr: 'AND', substitutionValues: {'info': "%Sant'Ana%"}) Example MySQL: whereRaw('b.info ilike ?', andOr: 'AND', substitutionValues: {'info': "%Sant'Ana%"}) Example: whereRaw( 'LOWER(${db.putInQuotes(sField.field)}::text) like ${db.formatSubititutioValue(sField.field)}', andOr: 'OR', substitutionValues: { 'nome': '%${filtros.searchString}%', });

Implementation

@override
QueryBuilder whereRaw(String whereRawSql,
    {String andOr = 'AND', Map<String, dynamic>? substitutionValues}) {
  final block = mBlocks![5] as WhereBlock;
  block.setWhereRaw(whereRawSql,
      andOr: andOr, substitutionValues: substitutionValues);
  return this;
}