Re: [dba-dev] Question 1: Finding the actual column name for an aliased field?

2010-02-09 Thread Ocke Janssen

Hi Drew,

Drew Jensen wrote:

On 2/9/2010 5:03 PM, Frank Schoenheit, Sun Microsystems Germany wrote:

Hi Drew,


I have a query:

SELECT "COL1" AS "ALIAS" FROM "TABLE"

Now I am handed a dataform in a routine and I need to find the column
names in the table, not the alias.


depending on which column object you have ... there might be a property
RealName, though I do not know, out of my head, at which col objects it
is available. So, try ControlModel.BoundField.RealName.




Nope - realname doesn't show up as a property for anything I can find.

That includes the query composer.

I thought there was a way to get this and realname sounds like it, but 
its gone as far as I can see.
When you use the SingleSelectQueryCompser and ask for the SelectColumns 
each column in that collection has a property RealName as well as a 
TableName property.


- oj


Drew

-
To unsubscribe, e-mail: dev-unsubscr...@dba.openoffice.org
For additional commands, e-mail: dev-h...@dba.openoffice.org




--
Ocke Janssen  Tel: +49 40 23646 661, x1
Dipl. Inf(FH) Fax: +49 40 23646 550
Sun Microsystems Inc.
Nagelsweg 55  mailto:ocke.jans...@sun.com
D-20097 Hamburg   http://www.sun.com/staroffice

Sitz der Gesellschaft:
Sun Microsystems GmbH, Sonnenallee 1, D-85551 Kirchheim-Heimstetten
Amtsgericht Muenchen: HRB 161028
Geschaeftsfuehrer: Thomas Schroeder, Wolfgang Engels
Vorsitzender des Aufsichtsrates: Martin Haering


-
To unsubscribe, e-mail: dev-unsubscr...@dba.openoffice.org
For additional commands, e-mail: dev-h...@dba.openoffice.org



Re: [dba-dev] Question 1: Finding the actual column name for an aliased field?

2010-02-09 Thread Drew Jensen

On 2/9/2010 5:03 PM, Frank Schoenheit, Sun Microsystems Germany wrote:

Hi Drew,


I have a query:

SELECT "COL1" AS "ALIAS" FROM "TABLE"

Now I am handed a dataform in a routine and I need to find the column
names in the table, not the alias.


depending on which column object you have ... there might be a property
RealName, though I do not know, out of my head, at which col objects it
is available. So, try ControlModel.BoundField.RealName.




Nope - realname doesn't show up as a property for anything I can find.

That includes the query composer.

I thought there was a way to get this and realname sounds like it, but 
its gone as far as I can see.


Drew

-
To unsubscribe, e-mail: dev-unsubscr...@dba.openoffice.org
For additional commands, e-mail: dev-h...@dba.openoffice.org



Re: [dba-dev] Question 1: Finding the actual column name for an aliased field?

2010-02-09 Thread Frank Schoenheit, Sun Microsystems Germany
Hi Drew,

> I have a query:
> 
> SELECT "COL1" AS "ALIAS" FROM "TABLE"
> 
> Now I am handed a dataform in a routine and I need to find the column 
> names in the table, not the alias.

depending on which column object you have ... there might be a property
RealName, though I do not know, out of my head, at which col objects it
is available. So, try ControlModel.BoundField.RealName.

Ciao
Frank

-- 
- Frank Schönheit, Software Engineer frank.schoenh...@sun.com -
- Sun Microsystems  http://www.sun.com/staroffice -
- OpenOffice.org Base   http://dba.openoffice.org -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-
To unsubscribe, e-mail: dev-unsubscr...@dba.openoffice.org
For additional commands, e-mail: dev-h...@dba.openoffice.org



[dba-dev] Question 1: Finding the actual column name for an aliased field?

2010-02-09 Thread Drew Jensen

Hi,

This has been interesting the last couple of days - even if it ends up 
not helping folks directly - it sure helped me.


My question for this email.

I have a query:

SELECT "COL1" AS "ALIAS" FROM "TABLE"

Now I am handed a dataform in a routine and I need to find the column 
names in the table, not the alias.


I thought that using the ResultsetColumn object and the properties

column.label = Alias
column.name = COL1

but no.

So am I just wrong on that?

Thanks

Drew

-
To unsubscribe, e-mail: dev-unsubscr...@dba.openoffice.org
For additional commands, e-mail: dev-h...@dba.openoffice.org