Home » Developer & Programmer » Reports & Discoverer » Error for report on view
Error for report on view [message #115520] Tue, 12 April 2005 07:26 Go to next message
wall_walker
Messages: 2
Registered: April 2005
Location: Karachi
Junior Member

Hi,
I m new to this forum. I have to create a report which will gather data from 4 Tables out of 2 Databases. So I created Database links & created a complex View. I m getting my required result in SQL and also in Reports but when I m calling report on the basis of Parameter, it throws me 2 errors:
ORA-01008, ORA-02063.
The iritating thing is that when I run report by giving direct value it runs but when I use Parameter and assign same value, it throws me above errors.

Plzzz, can anybuddy help.
Thanks in advance Smile
Re: Error for report on view [message #115523 is a reply to message #115520] Tue, 12 April 2005 08:18 Go to previous messageGo to next message
Steve Corey
Messages: 336
Registered: February 2005
Location: RI
Senior Member
It is very difficult to ascertain the problems you are having without a coded example. Also, if you are interested in the error messages I believe you can search the OTN (Oracle Technology Network -- www.oracle.otn.com) for documentation on the error messages, their meaning, and (possibly) how to remedy the problem. Reports help (within Builder) also offers limited help with error messages.

Good luck,
Steve

edit - forgot link to OTN

[Updated on: Tue, 12 April 2005 08:18]

Report message to a moderator

Re: Error for report on view [message #115535 is a reply to message #115523] Tue, 12 April 2005 09:33 Go to previous messageGo to next message
wall_walker
Messages: 2
Registered: April 2005
Location: Karachi
Junior Member

Thanks Steve for ur concern. I m sorry I should have given the coding.
I created my like this:

CREATE VIEW SAL AS SELECT M.BILLNO,M.BILLDATE,M.CCODE,C.ITCODE,C.KGS,(C.KGS*C.RATE)-(C.KGS*C.RATE*M.DISCOUNT*.01) AMT FROM MASTER M, CHILD C WHERE M.BILLNO=C.BILLNO AND M.TYPE='S' UNION
SELECT M.BILLNO,M.BILLDATE,M.CCODE,C.ITCODE,C.KGS,(C.KGS*C.RATE)-(C.KGS*C.RATE*M.DISCOUNT*.01) AMT FROM MASTER@DBLINK M, CHILD@DBLINK C WHERE M.BILLNO=C.BILLNO AND M.TYPE='S'

Now when I ran this query:

SELECT TO_CHAR(BILLDATE,'YY') YY, ITCODE, SUM(KGS), SUM(AMT) FROM SAL WHERE TO_CHAR(BILLDATE,'MON')='JAN' GROUP BY ITCODE, TO_CHAR(BILLDATE,'YY');

It gave me the required results but when I ran this in Report with a Parameter instead of 'JAN' and even passing 'JAN' in parameter it gave same errors.

Please check this again.
THANKS in advance Smile
Re: Error for report on view [message #115559 is a reply to message #115520] Tue, 12 April 2005 11:55 Go to previous message
Steve Corey
Messages: 336
Registered: February 2005
Location: RI
Senior Member
Consider the following example:

SELECT 
  TO_CHAR(sysdate, 'RR') YY
FROM 
  dual
WHERE 
  TO_CHAR(sysdate,'MON')= :p_month_abbreviation

 Substitute 'APR' for :p_month_abbreviation and yield '05'


You may need more assistance. In the meantime, look on metalink (metalink.oracle.com) or OTN for the error messages (and post here what they are). I have a feeling the errors are raised due to the way that BILLDATE is analyzed in relation to the parameter you are entering, but I am not sure without definitions of the errors.

Regards,
Steve
Previous Topic: Report Status - Terminated with Error
Next Topic: Oracle Reports 6i - Displaying Images for each field value
Goto Forum:
  


Current Time: Fri May 17 00:11:01 CDT 2024