문제

I have a very basic Esper question,what is the basic difference between OUTPUT WHEN and WHERE key word in Esper. Here is an example where i am using these Key Words.

select
  high
from 
  Bar
where
  getDirection() != Direction.FLAT;

and

select
  high
from 
  Bar
output when
  getDirection() != Direction.FLAT;
도움이 되었습니까?

해결책

"output when" batches up output until the condition turns true.

Always prefer filters over where-clauses: select high from Bar (direction != Direction.FLAT)

다른 팁

select high from Bar where getDirection() != Direction.FLAT; --> This statement will returns all you value in which getDirection()!= Direction.FLAT. It is something like you are comparing the values of that table with external values.

select high from Bar when getDirection() != Direction.FLAT; --> This statement returns all the values from Bar when your getDirection() != Direction.FLAT It is like you are fetching the values when certain condition is true.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top