Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> SQL Function question
We have a table (designed after a spreadsheet) of financial data.
Through functions we can locate the correct row in the table very efficiently.
Now what they want to do is select any field from the table for the returned row.
My first impression was to pass the field_name as a function argument, but have been unsuccessful in the execution.
Anybody got some sample code doing this type of scenario?
Example
Item Cost1 Cost2 Cost3 Cost4 Cost5 Total Screw .05 .01 .02 .04 0 .12 Tack .01 .03 .01 0 .06 .11
Return Cost2 for Tack. Then return Cost5 for Screw.
We currently have a function to return Total (hard coded), but if I can make the column totally flexible we wouldn't need the hard coded function. Received on Thu Jan 04 2001 - 12:09:30 CST
![]() |
![]() |