Posts by Douglas Heliston • 1 point
1 post
-
0
votes2
answers849
viewsA: Condition within the WHERE clause
You can filter as follows: select * from TABELA t WHERE TRUNC(T.DATASTAMP) BETWEEN '&DATA_INICIAL' AND '&DATA_FINAL' AND 1 = ( CASE WHEN &CT IS NOT NULL AND T.CENTRO_TRABALHO = &CT…