Subject Re: [Firebird-Architect] XSQLDA/XSQLVAR issues
Author Fabricio Araujo
On Sun, 09 Jan 2005 07:45:45 -0500, Jim Starkey wrote:

>
>Arno Brinkman wrote:
>
>>If i run this in MSSQL :
>>
>>SELECT
>> ID,
>> RELATIEID AS ALIAS
>>FROM
>> Orders
>>WHERE
>> ALIAS = 3668
>>
>>it fails with:
>>Invalid column name 'ALIAS'.
>>
>>AFAIK it only support aliasses in the ORDER BY clause and NOT in the WHERE,
>>GROUP BY, HAVING clauses.
>>
>>Running this on Oracle gives also a error:
>>ORA-00904: "ALIAS": invalid identifier
>>
>>
>>
>Running the following:
>
> select
> schema,
> tablename,
> tableid as id
> from
> system.tables
> where
> id=46
>
>in Netfrastructure dutifully gives
>
> SCHEMA TABLENAME ID
> ---------- ---------- --
>
> NETFRASITE MEMBERSHIP 46
>
>Last I heard, neither Oracle nor Microsoft were heavy Firebird users, so
>I had think their opinions should carry much weight.
>
>The important questions are:
>
> 1. Is it useful?

It´s very good to main readability of code, and you can change the
underlying field (if the other is of the same datatype) and no need to
track in query where you need to change.

>
>We really should encrypt pass1.cpp so only the most experienced,
>hardened, least impressionable programmers are exposed to such hideous,
>deplorable, disease infested, festering code. It is exactly the sort of
>code that makes me want to to make a special programmers' editor that
>supports block move but not cut and paste. Ugh.
>

Agreed.