General discussion
December 10, 2002 at 11:28 AM
jay johnson

SQL Basic: Referencing an Alias?

by jay johnson . Updated 23 years, 9 months ago

How does one reference another column in the same select statement by alias?

for example in:

Select (1 + 2) as mysum, (mysum*2) as doublemy um”

seems to cause an error.
My problem is that i have some very complex expressions and I need to be able to refer to their value repeatedly…

Thanks,!

This discussion is locked

All Comments