>Borislav,
>Thanks a lot for your example. I was able to mimic with my data . But result was obscure, spa_date was null everywhere for joins, unless artificially make in job2 record rucjob equal job_no. In any case it still draws all qty1 != 0 from jobs, so what was the purpose remains unclear. As you understood, it is someone's else code , so no idea why ALIAS() is used in select statement. Any side effects ?
>
Yes,
Your current ALIAS() can be different from this where you have all these fields.
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.