Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> SQL Question

SQL Question

From: Steve Haas <steven.haas_at_snet.net>
Date: Fri, 13 Jul 2001 04:28:54 -0700
Message-ID: <F001.00349A57.20010713042029@fatcity.com>

Good morning,
 

Env't:  Oracle 8.1.5, HP-UX 11.0 (64
bit)
 

Given the following tables:
emp with 100 rows
dept with 10 rows
 

and this SQL:
select emp.ename,
initcap(dept.deptname)
from emp.dept
where emp.deptno = emp.deptno;
 

The questions -
How many times is the initcap(dept.deptname) function actually "executed"?
Is it once for each emp row (100 times) or once for each dept row (10 times) or some other value?
 

Another scenario -
Would it be faster to retrieve rows with a bunch of similar functions (initcap, concatenations of columns and/or literals, etc) or to have and maintain the data in columns with the data formatted as such?
 

TIA gurus...
 

Steve HaasOpus Consultants,
LLC Received on Fri Jul 13 2001 - 06:28:54 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US