<s>
StreamSQL	B-Language
is	O
a	O
query	O
language	O
that	O
extends	O
SQL	B-Language
with	O
the	O
ability	O
to	O
process	O
real-time	O
data	B-General_Concept
streams	I-General_Concept
.	O
</s>
<s>
SQL	B-Language
is	O
primarily	O
intended	O
for	O
manipulating	O
relations	B-Language
(	O
also	O
known	O
as	O
tables	O
)	O
,	O
which	O
are	O
finite	O
bags	B-Language
of	O
tuples	B-Application
(	O
rows	O
)	O
.	O
</s>
<s>
StreamSQL	B-Language
adds	O
the	O
ability	O
to	O
manipulate	O
streams	O
,	O
which	O
are	O
infinite	O
sequences	O
of	O
tuples	B-Application
that	O
are	O
not	O
all	O
available	O
at	O
the	O
same	O
time	O
.	O
</s>
<s>
The	O
StreamSQL	B-Language
language	O
is	O
typically	O
used	O
in	O
the	O
context	O
of	O
a	O
Data	B-General_Concept
Stream	I-General_Concept
Management	I-General_Concept
System	I-General_Concept
(	O
DSMS	B-General_Concept
)	O
,	O
for	O
applications	O
including	O
market	O
data	O
analytics	O
,	O
network	O
monitoring	O
,	O
surveillance	O
,	O
e-fraud	O
detection	O
and	O
prevention	O
,	O
clickstream	O
analytics	O
and	O
real-time	O
compliance	O
(	O
anti-money	O
laundering	O
,	O
RegNMS	O
,	O
MiFID	O
)	O
.	O
</s>
<s>
Other	O
streaming	O
and	O
continuous	O
variants	O
of	O
SQL	B-Language
include	O
,	O
,	O
,	O
,	O
,	O
,	O
and	O
.	O
</s>
<s>
StreamSQL	B-Language
extends	O
the	O
type	O
system	O
of	O
SQL	B-Language
to	O
support	O
streams	O
in	O
addition	O
to	O
tables	O
.	O
</s>
<s>
A	O
standard	O
SELECT	O
statement	O
can	O
be	O
issued	O
against	O
a	O
stream	O
to	O
calculate	O
functions	O
(	O
using	O
the	O
target	O
list	O
)	O
or	O
filter	O
out	O
unwanted	O
tuples	B-Application
(	O
using	O
a	O
WHERE	O
clause	O
)	O
.	O
</s>
<s>
Each	O
tuple	B-Application
on	O
the	O
stream	O
is	O
joined	O
with	O
the	O
current	O
value	O
of	O
the	O
relation	O
based	O
on	O
a	O
predicate	O
to	O
produce	O
0	O
or	O
more	O
tuples	B-Application
.	O
</s>
<s>
Unioning	O
combines	O
tuples	B-Application
in	O
strict	O
FIFO	B-Operating_System
order	O
.	O
</s>
<s>
A	O
stream	O
can	O
be	O
windowed	O
to	O
create	O
finite	O
sets	O
of	O
tuples	B-Application
.	O
</s>
<s>
For	O
example	O
,	O
a	O
window	O
of	O
size	O
5	O
minutes	O
would	O
contain	O
all	O
the	O
tuples	B-Application
in	O
a	O
given	O
5	O
minute	O
period	O
.	O
</s>
<s>
Window	O
definitions	O
can	O
allow	O
complex	O
selections	O
of	O
messages	O
,	O
based	O
on	O
tuple	B-Application
field	O
values	O
.	O
</s>
<s>
Once	O
a	O
finite	O
batch	O
of	O
tuples	B-Application
is	O
created	O
,	O
analytics	O
such	O
as	O
count	O
,	O
average	O
,	O
max	O
,	O
etc.	O
,	O
can	O
be	O
applied	O
.	O
</s>
<s>
Tuples	B-Application
within	O
the	O
join	O
windows	O
will	O
combine	O
to	O
create	O
resulting	O
tuples	B-Application
if	O
they	O
fulfill	O
the	O
predicate	O
.	O
</s>
<s>
StreamSQL	B-Language
is	O
derived	O
from	O
academic	O
research	O
into	O
Event	B-Application
Stream	I-Application
Processing	I-Application
,	O
closely	O
related	O
to	O
complex	B-Operating_System
event	I-Operating_System
processing	I-Operating_System
.	O
</s>
<s>
Led	O
by	O
Michael	O
Stonebraker	O
,	O
a	O
team	O
of	O
30	O
professors	O
and	O
students	O
on	O
project	O
Aurora	O
worked	O
collaboratively	O
from	O
2001	O
through	O
2003	O
to	O
develop	O
the	O
core	O
principles	O
behind	O
StreamSQL	B-Language
.	O
</s>
