<s>
Structured	B-Language
Query	I-Language
Language	I-Language
,	O
abbreviated	O
as	O
SQL	B-Language
(	O
S-Q-L	O
,	O
sometimes	O
"	O
sequel	B-Language
"	O
for	O
historical	O
reasons	O
)	O
,	O
is	O
a	O
domain-specific	B-Language
language	I-Language
used	O
in	O
programming	O
and	O
designed	O
for	O
managing	O
data	O
held	O
in	O
a	O
relational	B-Application
database	I-Application
management	I-Application
system	I-Application
(	O
RDBMS	B-Application
)	O
,	O
or	O
for	O
stream	O
processing	O
in	O
a	O
relational	B-Application
data	I-Application
stream	I-Application
management	I-Application
system	I-Application
(	O
RDSMS	O
)	O
.	O
</s>
<s>
It	O
is	O
particularly	O
useful	O
in	O
handling	O
structured	B-Application
data	I-Application
,	O
i.e.	O
</s>
<s>
SQL	B-Language
offers	O
two	O
main	O
advantages	O
over	O
older	O
readwrite	O
APIs	B-General_Concept
such	O
as	O
ISAM	B-Application
or	O
VSAM	O
.	O
</s>
<s>
Firstly	O
,	O
it	O
introduced	O
the	O
concept	O
of	O
accessing	O
many	B-Application
records	O
with	O
one	O
single	O
command	O
.	O
</s>
<s>
with	O
or	O
without	O
an	O
index	B-Data_Structure
.	O
</s>
<s>
Originally	O
based	O
upon	O
relational	B-Algorithm
algebra	I-Algorithm
and	O
tuple	B-Application
relational	I-Application
calculus	I-Application
,	O
SQL	B-Language
consists	O
of	O
many	B-Application
types	O
of	O
statements	O
,	O
which	O
may	O
be	O
informally	O
classed	O
as	O
sublanguages	B-Application
,	O
commonly	O
:	O
a	O
data	B-Application
query	I-Application
language	I-Application
(	O
DQL	O
)	O
,	O
a	O
data	B-Language
definition	I-Language
language	I-Language
(	O
DDL	O
)	O
,	O
a	O
data	B-Application
control	I-Application
language	I-Application
(	O
DCL	O
)	O
,	O
and	O
a	O
data	B-Language
manipulation	I-Language
language	I-Language
(	O
DML	O
)	O
.	O
</s>
<s>
The	O
scope	O
of	O
SQL	B-Language
includes	O
data	O
query	O
,	O
data	O
manipulation	O
(	O
insert	O
,	O
update	O
,	O
and	O
delete	O
)	O
,	O
data	B-Language
definition	I-Language
(	O
schema	B-Application
creation	O
and	O
modification	O
)	O
,	O
and	O
data	O
access	O
control	O
.	O
</s>
<s>
Although	O
SQL	B-Language
is	O
essentially	O
a	O
declarative	B-Language
language	I-Language
(	O
4GL	B-Language
)	O
,	O
it	O
also	O
includes	O
procedural	B-Application
elements	O
.	O
</s>
<s>
SQL	B-Language
was	O
one	O
of	O
the	O
first	O
commercial	O
languages	O
to	O
use	O
Edgar	O
F	O
.	O
Codd	O
’s	O
relational	B-Architecture
model	I-Architecture
.	O
</s>
<s>
The	O
model	O
was	O
described	O
in	O
his	O
influential	O
1970	O
paper	O
,	O
"	O
A	O
Relational	B-Architecture
Model	I-Architecture
of	O
Data	O
for	O
Large	O
Shared	O
Data	O
Banks	O
"	O
.	O
</s>
<s>
Despite	O
not	O
entirely	O
adhering	O
to	O
the	B-Application
relational	I-Application
model	I-Application
as	I-Application
described	I-Application
by	I-Application
Codd	I-Application
,	O
it	O
became	O
the	O
most	O
widely	O
used	O
database	O
language	O
.	O
</s>
<s>
SQL	B-Language
became	O
a	O
standard	O
of	O
the	O
American	O
National	O
Standards	O
Institute	O
(	O
ANSI	O
)	O
in	O
1986	O
and	O
of	O
the	O
International	O
Organization	O
for	O
Standardization	O
(	O
ISO	B-General_Concept
)	O
in	O
1987	O
.	O
</s>
<s>
Despite	O
the	O
existence	O
of	O
standards	O
,	O
most	O
SQL	B-Language
code	O
requires	O
at	O
least	O
some	O
changes	O
before	O
being	O
ported	O
to	O
different	O
database	O
systems	O
.	O
</s>
<s>
SQL	B-Language
was	O
initially	O
developed	O
at	O
IBM	O
by	O
Donald	O
D	O
.	O
Chamberlin	O
and	O
Raymond	O
F	O
.	O
Boyce	O
after	O
learning	O
about	O
the	O
relational	B-Architecture
model	I-Architecture
from	O
Edgar	O
F	O
.	O
Codd	O
in	O
the	O
early	O
1970s	O
.	O
</s>
<s>
This	O
version	O
,	O
initially	O
called	O
SEQUEL	B-Language
(	O
Structured	O
English	O
Query	B-Language
Language	I-Language
)	O
,	O
was	O
designed	O
to	O
manipulate	O
and	O
retrieve	O
data	O
stored	O
in	O
IBM	O
's	O
original	O
quasirelational	O
database	O
management	O
system	O
,	O
System	B-Application
R	I-Application
,	O
which	O
a	O
group	O
at	O
IBM	O
San	O
Jose	O
Research	O
Laboratory	O
had	O
developed	O
during	O
the	O
1970s	O
.	O
</s>
<s>
Chamberlin	O
and	O
Boyce	O
's	O
first	O
attempt	O
at	O
a	O
relational	B-Application
database	I-Application
language	O
was	O
SQUARE	O
(	O
Specifying	O
Queries	O
in	O
A	O
Relational	O
Environment	O
)	O
,	O
but	O
it	O
was	O
difficult	O
to	O
use	O
due	O
to	O
subscript/superscript	O
notation	O
.	O
</s>
<s>
After	O
moving	O
to	O
the	O
San	O
Jose	O
Research	O
Laboratory	O
in	O
1973	O
,	O
they	O
began	O
work	O
on	O
a	O
sequel	B-Language
to	O
SQUARE	O
.	O
</s>
<s>
The	O
original	O
name	O
SEQUEL	B-Language
,	O
which	O
is	O
widely	O
regarded	O
as	O
a	O
pun	O
on	O
QUEL	B-Language
,	O
the	O
query	B-Language
language	I-Language
of	O
Ingres	B-Application
,	O
was	O
later	O
changed	O
to	O
SQL	B-Language
(	O
dropping	O
the	O
vowels	O
)	O
because	O
"	O
SEQUEL	B-Language
"	O
was	O
a	O
trademark	O
of	O
the	O
UK-based	O
Hawker	O
Siddeley	O
Dynamics	O
Engineering	O
Limited	O
company	O
.	O
</s>
<s>
The	O
label	O
SQL	B-Language
later	O
became	O
the	O
acronym	O
for	O
Structured	B-Language
Query	I-Language
Language	I-Language
.	O
</s>
<s>
After	O
testing	O
SQL	B-Language
at	O
customer	O
test	O
sites	O
to	O
determine	O
the	O
usefulness	O
and	O
practicality	O
of	O
the	O
system	O
,	O
IBM	O
began	O
developing	O
commercial	O
products	O
based	O
on	O
their	O
System	B-Application
R	I-Application
prototype	O
,	O
including	O
System/38	B-Device
,	O
SQL/DS	B-Application
,	O
and	O
IBM	B-Application
Db2	I-Application
,	O
which	O
were	O
commercially	O
available	O
in	O
1979	O
,	O
1981	O
,	O
and	O
1983	O
,	O
respectively	O
.	O
</s>
<s>
In	O
the	O
late	O
1970s	O
,	O
Relational	O
Software	O
,	O
Inc	O
.	O
(	O
now	O
Oracle	B-Application
Corporation	I-Application
)	O
saw	O
the	O
potential	O
of	O
the	O
concepts	O
described	O
by	O
Codd	O
,	O
Chamberlin	O
,	O
and	O
Boyce	O
,	O
and	O
developed	O
their	O
own	O
SQL-based	O
RDBMS	B-Application
with	O
aspirations	O
of	O
selling	O
it	O
to	O
the	O
U.S.	O
Navy	O
,	O
Central	O
Intelligence	O
Agency	O
,	O
and	O
other	O
U.S.	O
government	O
agencies	O
.	O
</s>
<s>
In	O
June	O
1979	O
,	O
Relational	O
Software	O
introduced	O
one	O
of	O
the	O
first	O
commercially	O
available	O
implementations	O
of	O
SQL	B-Language
,	O
Oracle	B-General_Concept
V2	O
(	O
Version2	O
)	O
for	O
VAX	B-Device
computers	O
.	O
</s>
<s>
By	O
1986	O
,	O
ANSI	O
and	O
ISO	B-General_Concept
standard	O
groups	O
officially	O
adopted	O
the	O
standard	O
"	O
Database	O
Language	O
SQL	B-Language
"	O
language	O
definition	O
.	O
</s>
<s>
The	O
SQL	B-Language
language	I-Language
is	O
subdivided	O
into	O
several	O
language	O
elements	O
,	O
including	O
:	O
</s>
<s>
Predicates	O
,	O
which	O
specify	O
conditions	O
that	O
can	O
be	O
evaluated	O
to	O
SQL	B-Language
three-valued	B-Language
logic	I-Language
(	O
3VL	B-Language
)	O
(	O
true/false/unknown	O
)	O
or	O
Boolean	O
truth	O
values	O
and	O
are	O
used	O
to	O
limit	O
the	O
effects	O
of	O
statements	O
and	O
queries	O
,	O
or	O
to	O
change	O
program	O
flow	O
.	O
</s>
<s>
This	O
is	O
an	O
important	O
element	O
of	O
SQL	B-Language
.	O
</s>
<s>
Statements	O
,	O
which	O
may	O
have	O
a	O
persistent	O
effect	O
on	O
schemata	O
and	O
data	O
,	O
or	O
may	O
control	O
transactions	B-General_Concept
,	O
program	O
flow	O
,	O
connections	O
,	O
sessions	O
,	O
or	O
diagnostics	O
.	O
</s>
<s>
SQL	B-Language
statements	O
also	O
include	O
the	O
semicolon	O
(";	O
"	O
)	O
statement	O
terminator	O
.	O
</s>
<s>
Though	O
not	O
required	O
on	O
every	O
platform	O
,	O
it	O
is	O
defined	O
as	O
a	O
standard	O
part	O
of	O
the	O
SQL	B-Language
grammar	O
.	O
</s>
<s>
Insignificant	O
whitespace	O
is	O
generally	O
ignored	O
in	O
SQL	B-Language
statements	O
and	O
queries	O
,	O
making	O
it	O
easier	O
to	O
format	O
SQL	B-Language
code	O
for	O
readability	O
.	O
</s>
<s>
SQL	B-Language
is	O
designed	O
for	O
a	O
specific	O
purpose	O
:	O
to	O
query	O
data	O
contained	O
in	O
a	O
relational	B-Application
database	I-Application
.	O
</s>
<s>
SQL	B-Language
is	O
a	O
set-based	O
,	O
declarative	B-Language
programming	I-Language
language	I-Language
,	O
not	O
an	O
imperative	B-Application
programming	I-Application
language	I-Application
like	O
C	B-Language
or	O
BASIC	O
.	O
</s>
<s>
However	O
,	O
extensions	O
to	O
Standard	O
SQL	B-Language
add	O
procedural	B-Application
programming	I-Application
language	I-Application
functionality	O
,	O
such	O
as	O
control-of-flow	O
constructs	O
.	O
</s>
<s>
In	O
addition	O
to	O
the	O
standard	O
SQL/PSM	B-Language
extensions	O
and	O
proprietary	O
SQL	B-Language
extensions	O
,	O
procedural	B-Application
and	O
object-oriented	B-Language
programmability	O
is	O
available	O
on	O
many	B-Application
SQL	B-Language
platforms	O
via	O
DBMS	O
integration	O
with	O
other	O
languages	O
.	O
</s>
<s>
The	O
SQL	B-Language
standard	O
defines	O
SQL/JRT	B-Language
extensions	O
(	O
SQL	B-Language
Routines	O
and	O
Types	O
for	O
the	O
Java	B-Language
Programming	I-Language
Language	I-Language
)	O
to	O
support	O
Java	B-Language
code	I-Language
in	O
SQL	B-Language
databases	I-Language
.	O
</s>
<s>
Microsoft	O
SQL	B-Language
Server	O
2005	O
uses	O
the	O
SQLCLR	B-Language
(	O
SQL	B-Language
Server	O
Common	O
Language	O
Runtime	O
)	O
to	O
host	O
managed	O
.NET	B-Application
assemblies	O
in	O
the	O
database	O
,	O
while	O
prior	O
versions	O
of	O
SQL	B-Language
Server	O
were	O
restricted	O
to	O
unmanaged	O
extended	O
stored	O
procedures	O
primarily	O
written	O
in	O
C	B-Language
.	O
PostgreSQL	B-Application
lets	O
users	O
write	O
functions	O
in	O
a	O
wide	O
variety	O
of	O
languages	O
—	O
including	O
Perl	B-Language
,	O
Python	B-Language
,	O
Tcl	B-Operating_System
,	O
JavaScript	B-Language
(	O
PL/V8	O
)	O
and	O
C	B-Language
.	O
</s>
<s>
SQL	B-Language
implementations	O
are	O
incompatible	O
between	O
vendors	O
and	O
do	O
not	O
necessarily	O
completely	O
follow	O
standards	O
.	O
</s>
<s>
PostgreSQL	B-Application
and	O
Mimer	B-Application
SQL	I-Application
strive	O
for	O
standards	O
compliance	O
,	O
though	O
PostgreSQL	B-Application
does	O
not	O
adhere	O
to	O
the	O
standard	O
in	O
all	O
cases	O
.	O
</s>
<s>
For	O
example	O
,	O
the	O
folding	O
of	O
unquoted	O
names	O
to	O
lower	O
case	O
in	O
PostgreSQL	B-Application
is	O
incompatible	O
with	O
the	O
SQL	B-Language
standard	O
,	O
which	O
says	O
that	O
unquoted	O
names	O
should	O
be	O
folded	O
to	O
upper	O
case	O
.	O
</s>
<s>
Popular	O
implementations	O
of	O
SQL	B-Language
commonly	O
omit	O
support	O
for	O
basic	O
features	O
of	O
Standard	O
SQL	B-Language
,	O
such	O
as	O
the	O
DATE	O
or	O
TIME	O
data	O
types	O
.	O
</s>
<s>
The	O
most	O
obvious	O
such	O
examples	O
,	O
and	O
incidentally	O
the	O
most	O
popular	O
commercial	O
and	O
proprietary	O
SQL	B-Language
DBMSs	O
,	O
are	O
Oracle	B-General_Concept
(	O
whose	O
DATE	O
behaves	O
as	O
DATETIME	O
,	O
and	O
lacks	O
a	O
TIME	O
type	O
)	O
and	O
MS	B-Language
SQL	B-Language
Server	O
(	O
before	O
the	O
2008	O
version	O
)	O
.	O
</s>
<s>
As	O
a	O
result	O
,	O
SQL	B-Language
code	O
can	O
rarely	O
be	O
ported	O
between	O
database	O
systems	O
without	O
modifications	O
.	O
</s>
<s>
The	O
complexity	O
and	O
size	O
of	O
the	O
SQL	B-Language
standard	O
means	O
that	O
most	O
implementers	O
do	O
not	O
support	O
the	O
entire	O
standard	O
.	O
</s>
<s>
indices	B-Data_Structure
,	O
file	O
storage	O
)	O
,	O
leaving	O
implementations	O
to	O
decide	O
how	O
to	O
behave	O
.	O
</s>
<s>
The	O
SQL	B-Language
standard	O
precisely	O
specifies	O
the	O
syntax	O
that	O
a	O
conforming	O
database	O
system	O
must	O
implement	O
.	O
</s>
<s>
Many	B-Application
database	O
vendors	O
have	O
large	O
existing	O
customer	O
bases	O
;	O
where	O
the	O
newer	O
version	O
of	O
the	O
SQL	B-Language
standard	O
conflicts	O
with	O
the	O
prior	O
behavior	O
of	O
the	O
vendor	O
's	O
database	O
,	O
the	O
vendor	O
may	O
be	O
unwilling	O
to	O
break	O
backward	B-General_Concept
compatibility	I-General_Concept
.	O
</s>
<s>
SQL	B-Language
was	O
adopted	O
as	O
a	O
standard	O
by	O
the	O
ANSI	O
in	O
1986	O
as	O
SQL-86	O
and	O
the	O
ISO	B-General_Concept
in	O
1987	O
.	O
</s>
<s>
It	O
is	O
maintained	O
by	O
ISO/IEC	O
JTC	O
1	O
,	O
Information	O
technology	O
,	O
Subcommittee	O
SC	O
32	O
,	O
Data	O
management	O
and	O
interchange	O
.	O
</s>
<s>
Until	O
1996	O
,	O
the	O
National	O
Institute	O
of	O
Standards	O
and	O
Technology	O
(	O
NIST	O
)	O
data-management	O
standards	O
program	O
certified	O
SQL	B-Language
DBMS	O
compliance	O
with	O
the	O
SQL	B-Language
standard	O
.	O
</s>
<s>
The	O
original	O
standard	O
declared	O
that	O
the	O
official	O
pronunciation	O
for	O
"	O
SQL	B-Language
"	O
was	O
an	O
initialism	O
:	O
(	O
"	O
ess	O
cue	O
el	O
"	O
)	O
.	O
</s>
<s>
Regardless	O
,	O
many	B-Application
English-speaking	O
database	O
professionals	O
(	O
including	O
Donald	O
Chamberlin	O
himself	O
)	O
use	O
the	O
acronym-like	O
pronunciation	O
of	O
(	O
"	O
sequel	B-Language
"	O
)	O
,	O
mirroring	O
the	O
language	O
's	O
prerelease	O
development	O
name	O
,	O
"	O
SEQUEL	B-Language
"	O
.	O
</s>
<s>
The	O
SQL	B-Language
standard	O
has	O
gone	O
through	O
a	O
number	O
of	O
revisions	O
:	O
</s>
<s>
Year	O
Name	O
Alias	O
Comments	O
1986	O
SQL-86	O
SQL-87	O
First	O
formalized	O
by	O
ANSI	O
1989	O
SQL-89	O
FIPS	O
127-1	O
Minor	O
revision	O
that	O
added	O
integrity	O
constraints	O
adopted	O
as	O
FIPS	O
127-1	O
1992	O
SQL-92	B-Language
SQL2	O
,	O
FIPS	O
127-2	O
Major	O
revision	O
(	O
ISO	B-General_Concept
9075	O
)	O
,	O
Entry	O
Level	O
SQL-92	B-Language
adopted	O
as	O
FIPS	O
127-2	O
1999	O
SQL:1999	B-Language
SQL3	B-Language
Added	O
regular	O
expression	O
matching	O
,	O
recursive	B-Language
queries	I-Language
(	O
e.g.	O
</s>
<s>
transitive	O
closure	O
)	O
,	O
triggers	B-Language
,	O
support	O
for	O
procedural	B-Application
and	O
control-of-flow	O
statements	O
,	O
nonscalar	O
types	O
(	O
arrays	O
)	O
,	O
and	O
some	O
object-oriented	B-Language
features	O
(	O
e.g.	O
</s>
<s>
structured	B-Language
types	I-Language
)	O
,	O
support	O
for	O
embedding	O
SQL	B-Language
in	O
Java	B-Language
(	O
SQL/OLB	B-Language
)	O
and	O
vice	O
versa	O
(	O
SQL/JRT	B-Language
)	O
2003	O
SQL:2003	B-Language
Introduced	O
XML-related	O
features	O
(	O
SQL/XML	B-Language
)	O
,	O
window	B-Language
functions	I-Language
,	O
standardized	O
sequences	O
,	O
and	O
columns	B-Application
with	O
autogenerated	O
values	O
(	O
including	O
identity	O
columns	B-Application
)	O
2006	O
SQL:2006	B-Language
ISO/IEC	O
9075-14:2006	O
defines	O
ways	O
that	O
SQL	B-Language
can	O
be	O
used	O
with	O
XML	B-Protocol
.	O
</s>
<s>
It	O
defines	O
ways	O
of	O
importing	O
and	O
storing	O
XML	B-Protocol
data	O
in	O
an	O
SQL	B-Language
database	I-Language
,	O
manipulating	O
it	O
within	O
the	O
database	O
,	O
and	O
publishing	O
both	O
XML	B-Protocol
and	O
conventional	O
SQL	B-Language
data	O
in	O
XML	B-Protocol
form	O
.	O
</s>
<s>
In	O
addition	O
,	O
it	O
lets	O
applications	O
integrate	O
queries	O
into	O
their	O
SQL	B-Language
code	O
with	O
XQuery	B-Language
,	O
the	O
XML	B-Language
Query	I-Language
Language	I-Language
published	O
by	O
the	O
World	O
Wide	O
Web	O
Consortium	O
(	O
W3C	O
)	O
,	O
to	O
concurrently	O
access	O
ordinary	O
SQL-data	O
and	O
XML	B-Protocol
documents	I-Protocol
.	O
</s>
<s>
2008	O
SQL:2008	B-Language
Legalizes	O
ORDER	O
BY	O
outside	O
cursor	O
definitions	O
.	O
</s>
<s>
Adds	O
INSTEAD	O
OF	O
triggers	B-Language
,	O
TRUNCATE	O
statement	O
,	O
FETCH	O
clause	O
2011	O
SQL:2011	B-Language
Adds	O
temporal	O
data	O
(	O
PERIOD	O
FOR	O
)	O
(	O
more	O
information	O
at	O
Temporal	O
database	O
#History	O
)	O
.	O
</s>
<s>
Enhancements	O
for	O
window	B-Language
functions	I-Language
and	O
FETCH	O
clause	O
.	O
</s>
<s>
The	O
standard	O
is	O
commonly	O
denoted	O
by	O
the	O
pattern	O
:	O
ISO/IEC	O
DIS	O
9075-n:yyyy	O
Part	O
n	O
:	O
title	O
,	O
or	O
,	O
as	O
a	O
shortcut	O
,	O
ISO/IEC	O
9075	O
(	O
The	O
term	O
'	O
DIS	O
 '	O
is	O
not	O
used	O
in	O
older	O
versions	O
)	O
.	O
</s>
<s>
Interested	O
parties	O
may	O
purchase	O
the	O
standards	O
documents	O
from	O
ISO	B-General_Concept
,	O
IEC	O
,	O
or	O
ANSI	O
.	O
</s>
<s>
ISO/IEC	O
9075	O
is	O
complemented	O
by	O
ISO/IEC	O
13249	O
:	O
SQL	B-Language
Multimedia	O
and	O
Application	O
Packages	O
and	O
some	O
Technical	O
reports	O
.	O
</s>
<s>
The	O
SQL	B-Language
standard	O
is	O
divided	O
into	O
10	O
parts	O
,	O
but	O
with	O
gaps	O
in	O
the	O
numbering	O
due	O
to	O
the	O
withdrawal	O
of	O
outdated	O
parts	O
.	O
</s>
<s>
ISO/IEC	O
9075-1:2016	O
Part	O
1	O
:	O
Framework	O
(	O
SQL/Framework	O
)	O
.	O
</s>
<s>
ISO/IEC	O
9075-2:2016	O
Part	O
2	O
:	O
Foundation	O
(	O
SQL/Foundation	O
)	O
.	O
</s>
<s>
ISO/IEC	O
9075-3:2016	O
Part	O
3	O
:	O
Call-Level	O
Interface	O
(	O
SQL/CLI	B-Language
)	O
.	O
</s>
<s>
It	O
defines	O
interfacing	O
components	O
(	O
structures	O
,	O
procedures	O
,	O
variable	O
bindings	O
)	O
that	O
can	O
be	O
used	O
to	O
execute	O
SQL	B-Language
statements	O
from	O
applications	O
written	O
in	O
Ada	B-Language
,	O
C	B-Language
respectively	O
C++	B-Language
,	O
COBOL	B-Application
,	O
Fortran	B-Application
,	O
MUMPS	B-Language
,	O
Pascal	B-Application
or	O
PL/I	O
.	O
</s>
<s>
(	O
For	O
Java	B-Language
see	O
part	O
10	O
.	O
)	O
</s>
<s>
SQL/CLI	B-Language
is	O
defined	O
in	O
such	O
a	O
way	O
that	O
SQL	B-Language
statements	O
and	O
SQL/CLI	B-Language
procedure	O
calls	O
are	O
treated	O
as	O
separate	O
from	O
the	O
calling	O
application	O
's	O
source	O
code	O
.	O
</s>
<s>
Open	B-Application
Database	I-Application
Connectivity	I-Application
is	O
a	O
well-known	O
superset	O
of	O
SQL/CLI	B-Language
.	O
</s>
<s>
ISO/IEC	O
9075-4:2016	O
Part	O
4	O
:	O
Persistent	O
stored	O
modules	O
(	O
SQL/PSM	B-Language
)	O
.	O
</s>
<s>
It	O
standardizes	O
procedural	B-Application
extensions	O
for	O
SQL	B-Language
,	O
including	O
flow	O
of	O
control	O
,	O
condition	O
handling	O
,	O
statement	O
condition	O
signals	O
and	O
resignals	O
,	O
cursors	O
and	O
local	O
variables	O
,	O
and	O
assignment	O
of	O
expressions	O
to	O
variables	O
and	O
parameters	O
.	O
</s>
<s>
In	O
addition	O
,	O
SQL/PSM	B-Language
formalizes	O
the	O
declaration	O
and	O
maintenance	O
of	O
persistent	O
database	O
language	O
routines	O
(	O
e.g.	O
,	O
"	O
stored	O
procedures	O
"	O
)	O
.	O
</s>
<s>
ISO/IEC	O
9075-9:2016	O
Part	O
9	O
:	O
Management	O
of	O
External	O
Data	O
(	O
SQL/MED	B-Language
)	O
.	O
</s>
<s>
It	O
provides	O
extensions	O
to	O
SQL	B-Language
that	O
define	O
foreign-data	O
wrappers	O
and	O
datalink	O
types	O
to	O
allow	O
SQL	B-Language
to	O
manage	O
external	O
data	O
.	O
</s>
<s>
External	O
data	O
is	O
data	O
that	O
is	O
accessible	O
to	O
,	O
but	O
not	O
managed	O
by	O
,	O
an	O
SQL-based	O
DBMS	O
.	O
</s>
<s>
ISO/IEC	O
9075-10:2016	O
Part	O
10	O
:	O
Object	O
language	O
bindings	O
(	O
SQL/OLB	B-Language
)	O
.	O
</s>
<s>
It	O
defines	O
the	O
syntax	O
and	O
semantics	O
of	O
SQLJ	B-Language
,	O
which	O
is	O
SQL	B-Language
embedded	O
in	O
Java	B-Language
(	O
see	O
also	O
part	O
3	O
)	O
.	O
</s>
<s>
The	O
standard	O
also	O
describes	O
mechanisms	O
to	O
ensure	O
binary	O
portability	O
of	O
SQLJ	B-Language
applications	O
and	O
specifies	O
various	O
Java	B-Language
packages	O
and	O
their	O
contained	O
classes	O
.	O
</s>
<s>
Unlike	O
SQL/OLB	B-Language
JDBC	B-Language
defines	O
an	O
API	B-General_Concept
and	O
is	O
not	O
part	O
of	O
the	O
SQL	B-Language
standard	O
.	O
</s>
<s>
ISO/IEC	O
9075-11:2016	O
Part	O
11	O
:	O
Information	O
and	O
definition	O
schemas	B-Application
(	O
SQL/Schemata	B-Language
)	O
.	O
</s>
<s>
It	O
defines	O
the	O
Information	O
Schema	B-Application
and	O
Definition	O
Schema	B-Application
,	O
providing	O
a	O
common	O
set	O
of	O
tools	O
to	O
make	O
SQL	B-Language
databases	I-Language
and	O
objects	O
self-describing	O
.	O
</s>
<s>
These	O
tools	O
include	O
the	O
SQL	B-Language
object	O
identifier	O
,	O
structure	O
and	O
integrity	O
constraints	O
,	O
security	O
and	O
authorization	O
specifications	O
,	O
features	O
and	O
packages	O
of	O
ISO/IEC	O
9075	O
,	O
support	O
of	O
features	O
provided	O
by	O
SQL-based	O
DBMS	O
implementations	O
,	O
SQL-based	O
DBMS	O
implementation	O
information	O
and	O
sizing	O
items	O
,	O
and	O
the	O
values	O
supported	O
by	O
the	O
DBMS	O
implementations	O
.	O
</s>
<s>
ISO/IEC	O
9075-13:2016	O
Part	O
13	O
:	O
SQL	B-Language
Routines	O
and	O
types	O
using	O
the	O
Java	B-Language
TM	O
programming	O
language	O
(	O
SQL/JRT	B-Language
)	O
.	O
</s>
<s>
It	O
specifies	O
the	O
ability	O
to	O
invoke	O
static	O
Java	B-Language
methods	O
as	O
routines	O
from	O
within	O
SQL	B-Language
applications	O
( 	O
 '	O
Java-in-the-database	O
'	O
)	O
.	O
</s>
<s>
It	O
also	O
calls	O
for	O
the	O
ability	O
to	O
use	O
Java	B-Language
classes	O
as	O
SQL	B-Language
structured	B-Language
user-defined	I-Language
types	I-Language
.	O
</s>
<s>
ISO/IEC	O
9075-14:2016	O
Part	O
14	O
:	O
XML-Related	O
Specifications	O
(	O
SQL/XML	B-Language
)	O
.	O
</s>
<s>
It	O
specifies	O
SQL-based	O
extensions	O
for	O
using	O
XML	B-Protocol
in	O
conjunction	O
with	O
SQL	B-Language
.	O
</s>
<s>
The	O
XML	B-Protocol
data	O
type	O
is	O
introduced	O
,	O
as	O
well	O
as	O
several	O
routines	O
,	O
functions	O
,	O
and	O
XML-to-SQL	O
data	O
type	O
mappings	O
to	O
support	O
manipulation	O
and	O
storage	O
of	O
XML	B-Protocol
in	O
an	O
SQL	B-Language
database	I-Language
.	O
</s>
<s>
ISO/IEC	O
9075-15:2019	O
Part	O
15	O
:	O
Multi-dimensional	O
arrays	O
(	O
SQL/MDA	O
)	O
.	O
</s>
<s>
It	O
specifies	O
a	O
multidimensional	O
array	O
type	O
(	O
MDarray	O
)	O
for	O
SQL	B-Language
,	O
along	O
with	O
operations	O
on	O
MDarrays	O
,	O
MDarray	O
slices	O
,	O
MDarray	O
cells	O
,	O
and	O
related	O
features	O
.	O
</s>
<s>
ISO/IEC	O
9075	O
is	O
complemented	O
by	O
ISO/IEC	O
13249	O
SQL	B-Language
Multimedia	O
and	O
Application	O
Packages	O
.	O
</s>
<s>
It	O
defines	O
interfaces	O
and	O
packages	O
based	O
on	O
SQL	B-Language
.	O
</s>
<s>
The	O
aim	O
is	O
unified	O
access	O
to	O
typical	O
database	O
applications	O
like	O
text	O
,	O
pictures	O
,	O
data	O
mining	O
,	O
or	O
spatial	B-General_Concept
data	I-General_Concept
.	O
</s>
<s>
ISO/IEC	O
9075	O
is	O
also	O
accompanied	O
by	O
a	O
series	O
of	O
Technical	O
Reports	O
,	O
published	O
as	O
ISO/IEC	O
TR	O
19075	O
.	O
</s>
<s>
These	O
Technical	O
Reports	O
explain	O
the	O
justification	O
for	O
and	O
usage	O
of	O
some	O
features	O
of	O
SQL	B-Language
,	O
giving	O
examples	O
where	O
appropriate	O
.	O
</s>
<s>
A	O
distinction	O
should	O
be	O
made	O
between	O
alternatives	O
to	O
SQL	B-Language
as	O
a	O
language	O
,	O
and	O
alternatives	O
to	O
the	O
relational	B-Architecture
model	I-Architecture
itself	O
.	O
</s>
<s>
Below	O
are	O
proposed	O
relational	O
alternatives	O
to	O
the	O
SQL	B-Language
language	I-Language
.	O
</s>
<s>
See	O
navigational	B-General_Concept
database	I-General_Concept
and	O
NoSQL	B-General_Concept
for	O
alternatives	O
to	O
the	O
relational	B-Architecture
model	I-Architecture
.	O
</s>
<s>
Datalog	B-Language
:	O
critics	O
suggest	O
that	O
Datalog	B-Language
has	O
two	O
advantages	O
over	O
SQL	B-Language
:	O
it	O
has	O
cleaner	O
semantics	O
,	O
which	O
facilitates	O
program	O
understanding	O
and	O
maintenance	O
,	O
and	O
it	O
is	O
more	O
expressive	O
,	O
in	O
particular	O
for	O
recursive	B-Language
queries	I-Language
.	O
</s>
<s>
JavaScript	B-Language
:	O
MongoDB	B-Application
implements	O
its	O
query	B-Language
language	I-Language
in	O
a	O
JavaScript	B-Language
API	B-General_Concept
.	O
</s>
<s>
QUEL	B-Language
introduced	O
in	O
1974	O
by	O
the	O
U.C.	O
</s>
<s>
Distributed	B-Language
Relational	I-Language
Database	I-Language
Architecture	I-Language
(	O
DRDA	B-Language
)	O
was	O
designed	O
by	O
a	O
workgroup	O
within	O
IBM	O
from	O
1988	O
to	O
1994	O
.	O
</s>
<s>
DRDA	B-Language
enables	O
network-connected	O
relational	B-Application
databases	I-Application
to	O
cooperate	O
to	O
fulfill	O
SQL	B-Language
requests	O
.	O
</s>
<s>
An	O
interactive	O
user	O
or	O
program	O
can	O
issue	O
SQL	B-Language
statements	O
to	O
a	O
local	O
RDB	O
and	O
receive	O
tables	B-Application
of	O
data	O
and	O
status	O
indicators	O
in	O
reply	O
from	O
remote	O
RDBs	O
.	O
</s>
<s>
SQL	B-Language
statements	O
can	O
also	O
be	O
compiled	O
and	O
stored	O
in	O
remote	O
RDBs	O
as	O
packages	O
and	O
then	O
invoked	O
by	O
package	O
name	O
.	O
</s>
<s>
It	O
is	O
especially	O
important	O
when	O
the	O
tables	B-Application
to	O
be	O
accessed	O
are	O
located	O
in	O
remote	O
systems	O
.	O
</s>
<s>
The	O
messages	O
,	O
protocols	O
,	O
and	O
structural	O
components	O
of	O
DRDA	B-Language
are	O
defined	O
by	O
the	O
Distributed	B-Operating_System
Data	I-Operating_System
Management	I-Operating_System
Architecture	I-Operating_System
.	O
</s>
<s>
Distributed	B-Language
SQL	I-Language
processing	O
ala	O
DRDA	B-Language
is	O
distinctive	O
from	O
contemporary	O
distributed	B-Language
SQL	I-Language
databases	O
.	O
</s>
<s>
SQL	B-Language
deviates	O
in	O
several	O
ways	O
from	O
its	O
theoretical	O
foundation	O
,	O
the	O
relational	B-Architecture
model	I-Architecture
and	O
its	O
tuple	B-Application
calculus	I-Application
.	O
</s>
<s>
In	O
that	O
model	O
,	O
a	O
table	O
is	O
a	O
set	O
of	O
tuples	B-Application
,	O
while	O
in	O
SQL	B-Language
,	O
tables	B-Application
and	O
query	O
results	O
are	O
lists	O
of	O
rows	B-Application
;	O
the	O
same	O
row	O
may	O
occur	O
multiple	O
times	O
,	O
and	O
the	O
order	O
of	O
rows	B-Application
can	O
be	O
employed	O
in	O
queries	O
(	O
e.g.	O
</s>
<s>
Critics	O
argue	O
that	O
SQL	B-Language
should	O
be	O
replaced	O
with	O
a	O
language	O
that	O
returns	O
strictly	O
to	O
the	O
original	O
foundation	O
:	O
for	O
example	O
,	O
see	O
The	O
Third	O
Manifesto	O
by	O
Hugh	O
Darwen	O
and	O
C.J.	O
</s>
<s>
The	O
lack	O
of	O
sum	B-Language
types	I-Language
has	O
been	O
described	O
as	O
a	O
roadblock	O
to	O
full	O
use	O
of	O
SQL	B-Language
's	O
user-defined	O
types	O
.	O
</s>
<s>
JSON	B-General_Concept
support	O
,	O
for	O
example	O
,	O
needed	O
to	O
be	O
added	O
by	O
a	O
new	O
standard	O
in	O
2016	O
.	O
</s>
<s>
The	O
concept	O
of	O
Nulls	O
enforces	O
the	O
3-valued-logic	O
in	O
SQL	B-Language
,	O
which	O
is	O
a	O
concrete	O
implementation	O
of	O
the	O
general	O
3-valued	B-Language
logic	I-Language
.	O
</s>
<s>
Another	O
popular	O
criticism	O
is	O
that	O
it	O
allows	O
duplicate	O
rows	B-Application
,	O
making	O
integration	O
with	O
languages	O
such	O
as	O
Python	B-Language
,	O
whose	O
data	O
types	O
might	O
make	O
accurately	O
representing	O
the	O
data	O
difficult	O
,	O
in	O
terms	O
of	O
parsing	O
and	O
by	O
the	O
absence	O
of	O
modularity	O
.	O
</s>
<s>
This	O
is	O
usually	O
avoided	O
by	O
declaring	O
a	O
primary	O
key	O
,	O
or	O
a	O
unique	O
constraint	O
,	O
with	O
one	O
or	O
more	O
columns	B-Application
that	O
uniquely	O
identify	O
a	O
row	O
in	O
the	O
table	O
.	O
</s>
<s>
In	O
a	O
similar	O
sense	O
to	O
object	B-Architecture
–	I-Architecture
relational	I-Architecture
impedance	I-Architecture
mismatch	I-Architecture
,	O
a	O
mismatch	O
occurs	O
between	O
the	O
declarative	B-Language
SQL	B-Language
language	I-Language
and	O
the	O
procedural	B-Application
languages	I-Application
in	O
which	O
SQL	B-Language
is	O
typically	O
embedded	O
.	O
</s>
<s>
The	O
SQL	B-Language
standard	O
defines	O
three	O
kinds	O
of	O
data	O
types	O
(	O
chapter	O
4.1.1	O
of	O
SQL/Foundation	O
)	O
:	O
</s>
<s>
User-defined	O
types	O
are	O
comparable	O
to	O
classes	O
in	O
object-oriented	B-Language
language	I-Language
with	O
their	O
own	O
constructors	O
,	O
observers	O
,	O
mutators	O
,	O
methods	O
,	O
inheritance	O
,	O
overloading	O
,	O
overwriting	O
,	O
interfaces	O
,	O
and	O
so	O
on	O
.	O
</s>
