Subject Request with Field Origin
Author Matt Nielsen
I've noticed that the new version of IBO now populates the origin
under all circumstances. I use this field for the same purpose that
IBO does to store the real tablename.fieldname I then use this for
different reasons but mostly for use on grids and column sorting and
building query statemens. The problem is that IBO doesn't generate
the correct origin if you have table aliasing. Meaning if I have the
following SQL:

SELECT
TABLEA.COLUMNA,
ALIASA.COLUMNA AS ALIASA_COLUMNA,
ALIASB.COLUMNA AS ALIASB_COLUMNB
FROM TABLEA
LEFT OUTER JOIN TABLEB ALIASA
ON (TABLEA.LINK1 = ALIASA.SEQNO)
LEFT OUTER JOIN TABLEB ALIASB
ON (TABLEA.LINK2 = ALIASB.SEQNO)

Then IBO would generate an origin for the for field ALIASA_COLUMNA as
TABLEB.COLUMNA when it should have generated ALIASA.COLUMNA.

A simple fix is that if the origin already has data in it then don't
overwrite it when IBO generates the field.

Another solution would be to teach the parser how to deal with table
aliases.

Another request would be to have the values of the origin at design
time not just runtime, certainly you would need to prevent it from
overwriting values if this was implemented.



Thanks,

Matt Nielsen
Caelix, Inc