Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: column aliases in views
Filipe David Borba Manana wrote:
> Jerome Vitalis wrote:
> > Filipe David Borba Manana wrote:
> >
> >> Replacing accountname with
> >> NVL(get_value(hostname,'/system/accounting/name'), 'undefined') works,
> >> although is not very elegant.
> >>
> >
> > Hadn't you read my answer which suggested to do so a long time ago? ;-)
>
> Yes, and I tried it. I was just trying to figure out if there was a more
> elegant alternative :)
> It seems there isn't any.
>
> Many thanks,
>
> Manana
Well obviously you could nest the query that defines the "accountname" and other expressions and refer to in in an outer query.
btw as well as POWER() being an existing SQL function (though you seem to get away with it somehow), is it possible for just one of the two "get_value" expressions to return NULL, in which case adding them together will return NULL, which the view will NVL into 0? If so, is that the result you want? Received on Sun Jan 14 2007 - 03:18:18 CST
![]() |
![]() |