[Bug 6117] [XQuery11UC] Windowing use case Q7 - error in logic


Tim Kraska <tim@flworfound.org> changed:

           What    |Removed                     |Added
                 CC|                            |tim@flworfound.org

--- Comment #2 from Tim Kraska <tim@flworfound.org>  2009-02-03 12:14:55 ---
The solution from Franc might cause several notifications. I would propose: 

declare variable $seq := fn:doc("person_events.xml");

  for tumbling window $w in $seq/stream/event 
    start  $s when $s/person eq "Anton" and $s/direction eq "in"
    only end $e next $n when  xs:dateTime($n/@time) - xs:dateTime($s/@time) gt 
      or  ($e/person eq "Barbara" and $e/direction eq "in") 
      or ($e/person eq "Anton" and $e/direction eq "out")
  where $e/person eq "Barbara" and $e/direction eq "in"
    <warning time="{ $e/@time }">Barbara: Anton arrived 1h ago</warning>

Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

Received on Tuesday, 3 February 2009 12:15:04 UTC