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

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Need assistance with a 'VIEW'.

RE: Need assistance with a 'VIEW'.

From: Jack C. Applewhite <japplewhite_at_inetprofit.com>
Date: Tue, 18 Sep 2001 15:19:53 -0700
Message-ID: <F001.00391F70.20010918144520@fatcity.com>

William,

Views can't prompt the User for values.

Maybe a stored function or procedure would be better? An application interface could store a User-provided Date in a public packaged variable, which could be referenced in the Where clause of the view.

Do you want to Group By just Code1,Code2 or Group By Code1,Code2,Date? In other words, do you want just one resultant row representing the aggregate of all rows with Date < InputDate, or a resultant row for every Date?

We need more info.

Jack



Jack C. Applewhite
Database Administrator/Developer
OCP Oracle8 DBA
iNetProfit, Inc.
Austin, Texas
www.iNetProfit.com
japplewhite_at_inetprofit.com
(512)327-9068

-----Original Message-----
Rogge
Sent: Tuesday, September 18, 2001 10:47 AM To: Multiple recipients of list ORACLE-L

I have been given the nice task of creating a view of some data in our database.

This doesn't seem like a major task, but after 2 days of work, I am stumped.

Given table 'table1'

   code1,
   code2,
   date,
   value1,
   value2

I need to produce a view showing

   code1,
   code2,
   sum(value1),
   sum(value2)
  where date < 'user input date'

I have not been able to get the view to prompt for the date to limit the sum by.

Specifics:
  Oracle RDMBS 7.3.4
  Server: Unix

What else can I say, but I am totally stumped. HELP!

--

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Jack C. Applewhite
  INET: japplewhite_at_inetprofit.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L

(or the name of mailing list you want to be removed from). You may
also send the HELP command for other information (like subscribing).
Received on Tue Sep 18 2001 - 17:19:53 CDT

Original text of this message

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