<s>
An	O
alias	B-Language
is	O
a	O
feature	O
of	O
SQL	O
that	O
is	O
supported	O
by	O
most	O
,	O
if	O
not	O
all	O
,	O
relational	O
database	O
management	O
systems	O
(	O
RDBMSs	O
)	O
.	O
</s>
<s>
Aliases	O
provide	O
database	B-General_Concept
administrators	I-General_Concept
,	O
as	O
well	O
as	O
other	O
database	O
users	O
,	O
with	O
the	O
ability	O
to	O
reduce	O
the	O
amount	O
of	O
code	O
required	O
for	O
a	O
query	B-Language
,	O
and	O
to	O
make	O
queries	B-Language
simpler	O
to	O
understand	O
.	O
</s>
<s>
In	O
SQL	O
,	O
you	O
can	O
alias	B-Language
tables	O
and	O
columns	B-Application
.	O
</s>
<s>
A	O
table	O
alias	B-Language
is	O
also	O
called	O
a	O
correlation	O
name	O
.	O
</s>
<s>
A	O
programmer	O
can	O
use	O
an	O
alias	B-Language
to	O
temporarily	O
assign	O
another	O
name	O
to	O
a	O
table	O
or	O
column	O
for	O
the	O
duration	O
of	O
a	O
SELECT	B-Language
query	I-Language
.	O
</s>
<s>
Assigning	O
an	O
alias	B-Language
does	O
not	O
actually	O
rename	O
the	O
column	O
or	O
table	O
.	O
</s>
<s>
This	O
is	O
often	O
useful	O
when	O
either	O
tables	O
or	O
their	O
columns	B-Application
have	O
very	O
long	O
or	O
complex	O
names	O
.	O
</s>
<s>
An	O
alias	B-Language
name	O
could	O
be	O
anything	O
,	O
but	O
usually	O
it	O
is	O
kept	O
short	O
.	O
</s>
<s>
For	O
example	O
,	O
it	O
might	O
be	O
common	O
to	O
use	O
a	O
table	O
alias	B-Language
such	O
as	O
"	O
pi	O
"	O
for	O
a	O
table	O
named	O
"	O
price_information	O
"	O
.	O
</s>
<s>
The	O
general	O
syntax	O
of	O
an	O
alias	B-Language
is	O
.	O
</s>
<s>
Here	O
is	O
some	O
sample	O
data	O
that	O
the	O
queries	B-Language
below	O
will	O
be	O
referencing	O
:	O
</s>
<s>
Using	O
a	O
table	O
alias	B-Language
:	O
</s>
<s>
We	O
can	O
also	O
write	O
the	O
same	O
query	B-Language
like	O
this	O
(	O
Note	O
that	O
the	O
AS	O
clause	O
is	O
omitted	O
this	O
time	O
)	O
:	O
</s>
<s>
A	O
column	O
alias	B-Language
is	O
similar	O
:	O
</s>
<s>
In	O
the	O
returned	O
result	B-Application
sets	I-Application
,	O
the	O
data	O
shown	O
above	O
would	O
be	O
returned	O
,	O
with	O
the	O
only	O
exception	O
being	O
"	O
DepartmentID	O
"	O
would	O
show	O
up	O
as	O
"	O
Id	O
"	O
,	O
and	O
"	O
DepartmentName	O
"	O
would	O
show	O
up	O
as	O
"	O
Name	O
"	O
.	O
</s>
<s>
Also	O
,	O
if	O
only	O
one	O
table	O
is	O
being	O
selected	O
and	O
the	O
query	B-Language
is	O
not	O
using	O
table	B-Language
joins	I-Language
,	O
it	O
is	O
permissible	O
to	O
omit	O
the	O
table	O
name	O
or	O
table	O
alias	B-Language
from	O
the	O
column	O
name	O
in	O
the	O
SELECT	O
statement	O
.	O
</s>
<s>
would	O
produce	O
the	O
same	O
result	B-Application
set	I-Application
as	O
before	O
.	O
</s>
<s>
In	O
the	O
example	O
,	O
an	O
alias	B-Language
was	O
provided	O
for	O
DepartmentId	O
,	O
but	O
omitted	O
for	O
DepartmentName	O
.	O
</s>
<s>
Columns	B-Application
with	O
unspecified	O
aliases	O
will	O
be	O
left	O
unaliased	O
.	O
</s>
