0

I need complex WHERE clause.

final Where where1 = new Where("col_1", Is.IN, "1, 2, 3");
final Where where2 = new Where("col_2", Is.IN, "a, b, c");
final Where where = where1.and(where2);

but in result i got

SELECT on table 'table', selection: 'col_1 IN (?) AND (col_2 IN (?))',
selectionArgs: '[1, 2, 3, a, b, c]', columns: 'null', orderBy: 'null',
groupBy: 'null', having: 'null', distinct: 'false', limit: 'null'.

as you see all arguments are put together and result fails.

Valery Kulikov
  • 319
  • 1
  • 12

1 Answers1

0

Should be

final Where where1 = new Where("col_1", Is.IN, 1, 2, 3);
final Where where2 = new Where("col_2", Is.IN, "a", "b", "c");
yanchenko
  • 56,576
  • 33
  • 147
  • 165