Report Formula Column

Hi All,
I need a help from you. I am working with reports. There I want to add 2 columns from two different groups from reports. It is like
GroupA
CF_1
GroupB
col1
GroupC
col2
GroupB and GroupC are linked by GroupA. Now I want to add col1 & col2 in CF_1 (formula column)
Message was edited by:
user613911

You'd better post this thread in (Reports Forum):
Reports
Greetings...
Sim

Similar Messages

  • Problem in Report Formula Column

    I recently Transfer my databse 9i to 10g and iam using developer 2.1 release 5 as a front hand.
    so problem is that my reports run successfully with oracle 9i but when i change my database to oracle 10g iam facing error in reports formula column. when i use select statement in formula column. i gave u an example about that.
    function CF_1Formula return Number is
         lc_count NUMBER;
    begin
         SELECT      count(*)
         INTO     lc_count
         FROM     tab;
         RETURN (NVL(lc_count,0));
    end;
    when i compile formula column i got this error.
    ORA-00600 internal error , argument:[17069], [19156148],[],[],[],[],[],[]
    please help me in this matter.
    Thanks.
    M.Sohail Tai

    hi fs,
    Thanks for reply me my friend.
    i also use the column name but same error is appeared when i compile formula column . this is only the example i gave to u. now i give u actual code.
    function CF_Close_Rate1Formula return Number is
    lc_rate number;
    begin
    select CL_RATES_CLOSE
    into lc_rate
    from sys_cl_rates
    where cp_id = :v_cp_id
    and loc_id = :v_loc_id
    and trade_type_id = :trade_type_id
    and cp_list_id = :cp_list_id
    and CL_RATES_DATE = (select max(cl_rates_date)
                   from sys_cl_rates
                   where cp_id = :V_CP_ID
                   and loc_id = :V_LOC_ID
                   and trade_type_id = :trade_type_id
                   and cp_list_id = :cp_list_id);
                   --= :lc_closing_date;
    return (nvl(lc_rate,0));
    EXCEPTION WHEN NO_DATA_FOUND THEN
    RETURN(0);
    end;
    This work properly with 9i database but not with 10g database.
    Reply me soon .
    Thanks,
    M.Sohail Tai

  • Export Oracle report formula column to XMLP

    hi
    i am thinking about exporting an rdf report to xmlp and i am worried about keeping my formula columns in the xmlpublisher report.
    what is gonna happen to them ?
    thx
    Dan

    If you are using Oracle Reports XML output as the datasource, the formula column will be in the XML, recognizable by the tag name. If you are using a data template to produce the datasource, the formula colum can be defined in the template.

  • Formula Columns are not working in Reports 10g

    Hi,
    We converted the reports developed in Reports 6i to Reports 10g. When we run the report in Reports 10g Builder everything works fine. But when we deploy the same report in Oracle Application Server and invoking the report the formula columns are not working ie., the fields/ placeholder columns which are based on the formula column are not displaying any values in the report.
    Please, someone help us in this regard.
    Thanks & Rgds,
    M T

    What version of Reports do you use..???
    Greetings...

  • Using PL/SQL in a formula column in Oracle Reports Builder.

    Hi,
    I need to SUM two record from the result of an SQL interrogation.
    Here's what it looks like
    function CF_1Formula return Number is
    nTot1 NUMBER :=0;
    nTot2 NUMBER :=0;
    begin
         select sum(:TOT1) into nTot1 from table(Q1) ;
         select sum(:TOT2) into nTot2 from table(Q1) ;
         return (nTot1 + nTot2);
    end;I'm kind of new to formula column programming any link of interest would be appreciated.
    The from table(Q1) part Q1 represents my SQL interrogation name and the group below it is G_MAIN.

    Hi Hong Kong King Kong,
    From looking at that function name (and the group name): Is this an Oracle Reports generated function?
    If so, there's also a dedicated Reports forum: Reports
    By the way, I like your synonym for 'query'.
    I'm sure I'll confuse some of my collegues tomorrow when I will mention 'database interrogation' instead of 'query'. ;)
    edit
    Doh...I should not underestimate the information that is posted in thread subjects.
    Edited by: hoek on May 5, 2010 9:24 PM

  • How to add a formula column in a report

    Hi
    I have made a report based on a query.
    There are 3 columns in the query and all the 3 are displayed.
    Now I want to add a new column (fomula column) to the report.
    I want to write a query inside the formula column. To execute the query col1, col2 and col3 values are required in the formula column.
    Could you please tell me how to add a formula column in the report and how to pass database column value to inside the formula column
    regards

    Here is how you would create a formula column:
    Open data model of the report.
    Formula column button is on the left side of the tool palette.
    Click on that button.
    Now click in the query group where you want to place the formula column.
    You would see a new field something like CF_1. That is the formula column.
    Double click on the field CF_1. It will open property inspector.
    You would see, Datatype of the formula column is Number. Change this as per your requirement.
    Double click on PL/SQL Formula property. It would open up a editor. Here you can write the code.
    And now to access the data model column here, you can use : and column name. i.e. :col1 or :col2, etc
    And remember you have to return the value back to the formula column. Like this: RETURN(some value).
    You can also take a help from here:
    http://download.oracle.com/docs/html/B13895_01/orbr_howto.htm#sthref1309
    Hope this helps.

  • REP-1425 report formula DO_SQL error putting value into column

    Hi all
    I have opened a report 2.5 in Oracle9i Reports Developer and, it converted ok. However, when I run the report (paper layout), the message
    rep-1425 report formula DO_SQL error putting value
    into column. Column may not be referenced by parameter
    triggers
    appears. There are several report level formula columns and corresponding placeholder columns that are the cause of this error. The formula has the following :
    SRW.DO_SQL('SELECT RPAD(''DAILY TABLE AUDIT REPORT'',60,''.'')||TO_CHAR(SYSDATE,''DD-MON-YYYY'') INTO :REPORT_TIT FROM DUAL');
    COMMIT;
    RETURN('');
    I can't work out what this error message really means as the column, report_tit is a placeholder column and, the formula column is not a parameter trigger!! The report_tit placeholder is used as a source for a layout field. I noticed that the layout field is defined as a placeholder column in the converted report but in the reports 2.5 version, it is defined as a layout field.
    I can do a work around by replacing the SRW.DO_SQL statement with a normal PL/SQL SELECT statement. However, I wonder if anyone else has had the same problem and, if anyone can help provide an answer as to what this error really means and, also, how I can retain the SRW.DO_SQL statement and/or an alternative work around to the one that I have described.
    Thanks.
    Therese Hughes
    Forest Products Commision

    Hi again
    The firewall proved to be the problem after all! The firewall set in Reports config-files is not used for WebServices, it has to be set within the stub:
    Properties prop = System.getProperties();
    prop.put("http.proxyHost","yourProxyServer");
    prop.put("http.proxyPort","youProxyServerPort");
    I inserted this in my java-code and after some problems (see below), restarting Report Builder turned the trick, the report works now.
    Cheers
    Tino
    Here there mail I set up before I found that restarting Report Builder helped:
    Thanks for your answer, putting in the proxy-settings actually helped some - the same error message is
    popping up, but instantly and not after 10 seconds like before:
    My proxy lines look like this, I also tried "http://proxy.ch.oracle.com", but "proxy.ch.oracle.com" proved to
    be the correct syntax:
    public Float getRate(String country1, String country2) throws Exception
    Float returnVal = null;
    Properties prop = System.getProperties();
    prop.put("http.proxyHost","proxy.ch.oracle.com");
    prop.put("http.proxyPort","8080");
    URL endpointURL = new URL(endpoint);
    Call call = new Call();
    I tested the new proxy-entries by disabling the proxy preference in JDeveloper, so I could verify the added
    proxy-lines in the code work - they do. If I change the proxy to some incorrect value like
    "proxyy.ch.oracle.com", they fail.
    After unsuccessfully trying recompile and re-import of Java classes, I rebuild the report from scratch and
    stumbled over the same problem. Now the question is, whether I'm still doing something wrong with the
    proxy or whether there is another problem after passing the firewall....
    -------------------------------------------------------------------------------------------------------------

  • Formula Column in Report 9i Builder

    Hi,
    I use this configuration
    Report Builder 9.2.0.1.0
    Windows XP Service Pack 1
    NLS_LANG "BRAZILIAN PORTUGUESE_BRAZIL.WE8ISO8859P1"
    When I try to create a formula column that returns number, I have to choose datatype 'Nu'mero' (with accented u)as this is the only avaiable in the combo box. However when I write this PL/SQL code for the column:
    function CF_17Formula return Number is
    begin
    RETURN(1);
    end;
    Reports gives me the message:
    REP-0737: Deve ser uma funcao com retorno do tipo 'nu'mero'.
    In English this message could be
    REP-0737: Should be a function with return type 'nu'mero'.
    I don't have this problem with Character or Date formula columns (these datatypes are called Caracter and Data in Portuguese).
    It seems that Reports is having problems with u' (accented u) character. If I change NLS_LANG to AMERICAN_AMERICA.WE8ISO8859P1 everything works fine because I can choose Number in the Formula Column Datatype in the Property Inspector.
    The problem is in the function declaration not in the Return statement.
    Could anyone help me? Tks.
    Edmar

    Edmar,
    You are right. I could reproduce this issue.
    I have filed a bug to fix it from the development in next patch
    Thanks
    The Oracle Reports Team

  • Formula Column in Report template

    I have a report template to use in all the report. I want to have a formula column on it to take a control value(location/Organization) where the report is being printing. Is it possible to have a formula column in a report template? if it possible how can I do it? otherwise how can i achieve this task?
    Thank in advance
    Muza.

    What is the application release?
    Can you find any details about the error in the OPP log file?
    Please search MOS website for "Cannot view XML input using XSL style sheet" and go through the docs.
    Thanks,
    Hussein

  • Report output order by formula column value? pls.urgent

    hi.
    i have one query select empno,ename, sal from emp. in report layout i created a formula column named as net_sal(in which am doing some calculation based on some criteria). now i want to print the report order by net_sal desc.
    how can i solve it? since the calculation is being done on runtime only/
    pls. help me. urgent

    Puedes hacer lo sigte.:
    En el SQL QUERY STAMENT
    select empno, ename, sal, :net_sal
    from emp
    order by 4 asc/desc

  • Formula Column in Matrix Report (Running Balance)

    Hi all. I hope somebody can help me.
    I am working on a matrix report using multi-query data models. The report has 2 groups in the horizontal axis and 3 groups in the vertical axis. The intersection is not just a single row but may consist of multiple rows.
    My problem is this. I want to create a column in the intersection which is obtained by using a column value from the lowest group in the vertical axis and a summary column obtained from the rows of the intersection.
    Here's what my report looks like:
    2002 (accross)
    2002(down) january february (accross)
    January (down) payments balance payments balance
    loan #1 10,000 500 9,000 200 8,800
    500
    loan #2 5,000 100 4,900 200 4,700
    February
    loan #3 3,500 0 3,500 50 3,450
    loan #4 4,200 0 4,200 0 4,200
    As you can see, the loans are grouped by month and year. And the payments are grouped for the month and year too.
    The data model is :
    For Query 1 (Vertical Axis),
    1st group - Loan Yr
    2nd group - Loan Mo
    3rd group - Loan # and amount
    For Query 2 (Horizontal Axis)
    1st group - Payment Yr
    2nd group - Payment Mo
    Intersection Group - Payment Amount
    My problem actually is how to compute for the running balance of the loan for each month in the horizontal axis. Ive already created a cross product summary to get the running total of the payments made for the month. I tried creating a formula column to for the running balance by subtracting it from the loan amount but i get the error "incompatible frequency"
    I hope i have described my problem well and thanks for the help

    The problem is that you're trying to reference dimension columns(loan Amount) in the calculation of matrix cell values. You can only reference other matrix cell values or cross product columns (summary, formula, placeholders) when calculating matrix cell values. Try moving the (loan Amount) column down to the matrix cell - something like:
    For Query 1 (Vertical Axis),
    1st group - G_LoanYear(LoanYr)
    2nd group - G_LoanMonth(LoanMo)
    3rd group - G_LoanNumber(Loan#)
    For Query 2 (Horizontal Axis)
    1st group - G_PaymentYear(PaymentYr)
    2nd group - G_PaymentMonth(PaymentMo)
    Intersecion /Detail Group - G_Details(PaymentAmount, LoanAmount)
    Then create the following Matrix summary columns:
    A running summary - CS_Payments:
    - Product Order: G_LoanYear G_LoanMonth G_LoanNumber G_PaymentYear G_PaymentMonth
    - Source: PaymentAmount
    - Function: Sum
    - Reset At: G_LoanNumber
    The total amount per loan - CS_TotalPayment:
    - Product Order: G_LoanYear G_LoanMonth G_LoanNumber
    - Source: LoanAmount
    - Function: First
    - Reset At: G_LoanNumber
    The value of the loan after each payment - CF_Countdown:
    - Product Order: G_LoanYear G_LoanMonth G_LoanNumber G_PaymentYear G_PaymentMonth
    - PL/SQL Formula:
    function CF_CountdownFormula return Number is
    begin
    return(:CS_TotalPayment - :CS_Payments);
    end;
    You should then be able to display "CF_Payments" and "CF_Countdown" in the matrix cell to show how much has been paid and how much is still owed.
    You can still have another "loan amount" as a dimension column - you just don't need to use it when calculating the values in the cell.

  • Howto use formula columns in matrix reports

    Hello
    How can i use a formula column in matrix report whose function would be
    Formula_Column_Result=A-B where A=Cell A
    B =Cell B
    Regards
    Fahad

    Hii guys
    I solved my problem on my own.
    i wrote
    SELECT * FROM EMP WHERE EMP.DEPTNO=P_DEPT_NO
    and it worked.
    Thanks guys..i luv this forum
    Regards
    Fahad Hameed

  • Report Builder chrashes when creating a new formula column

    Dear all,
    whenever I try to create a new formula column in the data model, that is placed outside of a query, my report builder crashes completely. The same happens on my colleagues notebook.
    If anyone has an idea why this could happen, please let me know. I am currently using Version 9.0.4.1.0.
    Thanks and br
    Daniel

    You can keep the report builder you have now. Just install the new one in new oracle home. You can download it from here
    http://www.oracle.com/technology/software/products/ids/htdocs/904winsoft.html
    This download has Developer Suite 10g (Report 9.0.4.0.33, Form 9.0.4.0.19, JDeveloper, Discoverer, Designer)
    I don't think so you can select which product you want to install, like it was in 6i. So it will install everything.
    Try to install this version. Hope this will help.
    Thanks
    FS

  • Not able to burst report referring to Formula Column in XML file.

    Hello all,
    I am using bursting feature to spit single report to multiple pdfs. All is well when I reference column queried from the database in the xml file but I when I give column from Formula column it is doing coredump.
    XML File contents:
    =====================
    <destinations>
    <!-- Generate a file for each warehouse -->
    <foreach>
    <file id="MyFiles" name="/data/reports/pdf/assrt_terr&amp;&lt;file_name&gt;.pdf" format=
    "pdf" instance="this">
    <include src="report"/>
    </file>
    </foreach>
    </destinations>
    =====================
    The "file_name" referenced in the above is a formula column. If it is replace with a column from the query it works fine. Please let me know if anyone knows if it is a limitation or any workaround?
    Thanks in advance,
    Manohar

    If I can have that in the query I would have not done a formula column. And I do know that it works if the column is in the query. I would like to know any workaround to make it work from formula column.
    I have to take data from sub-group of this query, aggregate it and then concatinate with one of the columns grouped - so i had to use formula column.
    Thanks
    Manohar

  • About formula column in oracle report

    I want the output value of the formula column in my report between two brackts ....ex: (28.99) ...can anyone give me the idea

    Do u mean that brackets have to be appeared only when the value is +ve/-ve. then you need to use (9999) in the format mask of the property pallette of the text column. if you want to use the brackets for all the data, then the solution has been provided by many of our frnds.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

Maybe you are looking for

  • My Mac can no longer find my Time Capsule or my home network.

    Hello, having had no problems for the first few months I can no longer get online. My Mac cannot find my network (but can find all of the other networks on my street) and cannot find the Time Capsule. The Time Capsule itself has a green light so I as

  • Linux & learning software. your tips/tricks/experiences w/ studying.

    Hey everyone, I'm a college/university student and find myself using my laptop a lot for studying lately. I use it mainly as a substitute for pen and paper so I'm wondering how I could make even better use of the PC/laptop while learning. Enter threa

  • Update (All Mapped Fields) Import Action creates a new record.....

    Hi All, I am on MDM 5.5 sp6,and this weird thing happens everytime i run the "update all mapped fields" option in the import manager,it creates a new duplicate field with the updated value record.Is this  a bug in sp6 or I guess i am going wrong some

  • Best way to extract XML data to DB

    Hello, In our work we need to extract data from XML documents into a database. Here are some extra notes: + There is no constant schema for the XML documents. + Some processing on the XML files is required. + The XML documents are very big. + The dat

  • Facebook pictures not loading

    Hi, I am sorry about that. I did not catch that on your original post. We would like to further investigate this issue. For anyone experiencing this issue and have tried changing the DNS and disabling IPv6, please send us a detailed message by clicki