Report based on sql or plsql

Hello,
I have an LOV_COLS, which contains the columns of scott.emp and is represented by a list P50_MY_COLS, and textfield P50_SEARCHTERM where I can enter a search term.
Now I like to have a report which displays something like SELECT EMPNO, ENAME, MGR, SAL, COMM FROM EMP WHERE UPPER(:P50_MY_COLS) LIKE UPPER(:P50_SEARCHTERM) if a button P50_SEARCH is pressed.
I'd like also to control the Columns if they contain NULL. The report should display the respective rows after pressing the Button P50_NULLSEARCH
After the desired rows are reported I'd like to be abel to edit the rows...
How can this be realized ? What is the source of the report ?
I use the Apex 2.1 which comes with the Oracle XE installation.
Can someone provide an example ?
Where in the docs are the differences (with examples) of the different sql and plsql based reports explained ?
Can a report by based on a plsql procedure/function which resides in the database (not inside the Apex-pages) ?
thx in advance
Edited by: wucis on Mar 10, 2011 1:17 PM

Sharmila,
Thanks for your response. Maybe I wasn't clear enough in my previous statement. I will give an example of what I am trying to accomplish.
Let's say I have 2 date fields(SUBMITDATE,COMPLETEDATE) in a table TABLE A
I want to calculate a field called CYCLETIME with the following conditions:
If COMPLTEDATE is NULL, then CYCLETIME = SYSDATE-SUBMITDATE
IF COMPLTEEDATE is not null, then CYCLETIME = COMPLTEEDATE-SUBMITDATE
Would appreciate any help.
Thanks
Dev
Hi,
You can do the calculation in the sql query itself. Here is an example which shows the sum of salaray for each department in the scott.emp table.
select deptno,sum(sal) sal
from scott.emp
group by deptno
Thanks,
Sharmila

Similar Messages

  • Bold a single row in a Report based on SQL Query

    Should be easy? So, how do I bold a single row in a report based on SQL query without creating a new template or writing Java for the page? What is the Tabular Form Element "Element Attributes" field for? Or what am I supposed to put in there to make it do anything?

    One way to do this is to add a hidden column to your report which contains the formatting value, for example:
    select empno
    , ename
    , sal
    , decode(empno,1,'font-weight:bold','font-weight:normal') style
    from emp
    Hide the STYLE column.
    Then you can use this column for each column in Column Formatting > HTML expression in this way:
    <span style="#STYLE#">#SAL#</span>
    Unfortunately you have to do this for each colum you want to appear bold.
    good luck,
    Dirk Dral

  • Report Based on SQL view not pulling in all parameters

    Post Author: ronhawker
    CA Forum: .NET
    I based a report on a SQL view below:SELECT     TOP (100) PERCENT CorpDirectory.Position, CorpDirectory.PhoneDirect, CorpDirectory.Email, CorpDirectory.Store, CorpDirectory.Name,                       CorpDirectory.PhoneFaxWave, CorpDirectory.Department, Store.StoreName, Store.StoreStreetAddress, Store.StoreCity, Store.StoreState,                       Store.StoreZip, Store.StorePhone, CorpDirectory.DisplayOrderFROM         dbo.CorpDirectory AS CorpDirectory INNER JOIN                      dbo.Store AS Store ON CorpDirectory.Store = Store.StoreORDER BY CorpDirectory.Store, CorpDirectory.Department, CorpDirectory.DisplayOrder, CorpDirectory.Name When the report was created the order by sequence only brought in the first parameter of CorpDirectory.Store. It seemed to ignore the other three order by parameters. I am running 10.2 is VS2005.

    Sharmila,
    Thanks for your response. Maybe I wasn't clear enough in my previous statement. I will give an example of what I am trying to accomplish.
    Let's say I have 2 date fields(SUBMITDATE,COMPLETEDATE) in a table TABLE A
    I want to calculate a field called CYCLETIME with the following conditions:
    If COMPLTEDATE is NULL, then CYCLETIME = SYSDATE-SUBMITDATE
    IF COMPLTEEDATE is not null, then CYCLETIME = COMPLTEEDATE-SUBMITDATE
    Would appreciate any help.
    Thanks
    Dev
    Hi,
    You can do the calculation in the sql query itself. Here is an example which shows the sum of salaray for each department in the scott.emp table.
    select deptno,sum(sal) sal
    from scott.emp
    group by deptno
    Thanks,
    Sharmila

  • Reports based on SQL view contain no data. Reports based on tables work just fine

    When we load a report into Crystal reports server that is based on a SQL view the report will run but will contain no data. A report that pulls data from SQL tables works just fine. Running the crystal report on standalone crystal reports works just fine.
    I am completely lost on this one. If you have any ideas please send them my way.

    Are you missing an ODBC / TNS entry on your CMS (or report processing, if clustered env) server?  This could definately be an issue if the report will run locally within CR client, but not when hosted on the enterprise environment.  Another test would be to run the report from CR client ON the CRS / BOE server..

  • Report Layout width(Report based on SQL Query)

    Is there any way to increase the width of the report layout? I have removed as many columns as I can and dropped the font size down but the data in the columns is still wrapping to more than one line. How can I increase the report layout width, or change the layout to landscape or something similar.
    thanks

    I had this problem with wrapping text. You have to create a Reports From SQL Query and choose a custom layout. Then when you go the the HTML layout section, you will need to ad nowrap to the <TD> tag (i.e. <TD nowrap>) for each field you do not want to wrap.
    Martin

  • Regions - Reports (based on sql) - Radio Buttons

    Hi there
    Trying to do :
    Selecting an option from Radiogroup, want to see certain report (summary). That report have a column that has a link to another page.
    RadioGroup :
    Options
    View 1
    View 2
    View1
    Column1 (link), Column2, Column3, Column4
    View2
    Column1 (link), Column2, Column3
    Note By
    Select Option 1, show only Report 1 - View 1, View 2 invisible.
    Any ideas ?
    Can't figure how ?
    Region Definition is ok (when switching) but format side of report attributes is tricky...can't get that to switch...
    DECLARE
    q VARCHAR2(32767); -- query
    w VARCHAR2(4000) ; -- where clause
    we VARCHAR2(1) := 'N'; -- identifies if where clause exists
    BEGIN
    If :P9_VIEWS ='0'
    THEN
    q := 'SELECT
    A.CIP_NUMBER2,
    A.CIP_NUMBER CIP_NO,
    A.ACTION_DEPARTMENT,
    A.TITLE,
    A.ACTION_BY,
    A.DATE_RAISED2,
    A.DUE_BY,
    A.REMEDIAL_ACTION_DATE2,
    A.CA_DATE2,
    A.CAC_DATE2,
    A.PA_DATE2,
    A.PAC_DATE2
    from
    westgarth.cis_report_4_details A';
    IF :P9_DEPARTMENT != '-1'
         THEN
         IF we = 'Y'
              THEN
                   w := w || ' AND A.ACTION_DEPARTMENT = :P9_DEPARTMENT';
              ELSE
                   w := ' A.ACTION_DEPARTMENT = :P9_DEPARTMENT';
                   we := 'Y';
         END IF;
    END IF;
    IF :P9_ACTION_BY != '-1'
         THEN
         IF we = 'Y'
              THEN
                   w := w || ' AND A.ACTION_BY = :P9_ACTION_BY';
              ELSE
                   w := ' A.ACTION_BY = :P9_ACTION_BY';
                   we := 'Y';
         END IF;
    END IF;
    IF (:P9_FROM != 'DD-MMM-YY' or :P9_FROM !='') AND (:P9_TO != 'DD-MMM-YY' or :P9_TO !='')
         THEN
         IF we = 'Y'
              THEN
                   w := w || ' AND A.REMEDIAL_ACTION_DATE2
    BETWEEN :P9_FROM AND :P9_TO';
              ELSE
                   w := ' A.REMEDIAL_ACTION_DATE2 BETWEEN :P9_FROM AND :P9_TO ';
                   we := 'Y';
         END IF;
    END IF;
    IF :P9_OVERDUE_ITEMS !='0'
         THEN
         If we = 'Y'
              THEN
                   W := W || ' AND SYSDATE > A.REMEDIAL_ACTION_DATE2';
              ELSE
                   W := ' SYSDATE > A.REMEDIAL_ACTION_DATE2';
                   we := 'Y';
         END IF;
    END IF;
    IF we = 'Y'
         THEN q := q || ' WHERE '|| w;
    END IF;
    --wwv_flow.debug(' query is:' || q);
    RETURN q;
    ELSE
    q := 'SELECT
    A.CIP_NUMBER2,
    A.CIP_NUMBER CIP_NO,
    A.ACTION_DEPARTMENT,
    A.TITLE,
    A.DESCRIPTION,
    A.ACTION_BY,
    A.DATE_RAISED2,
    A.DUE_BY,
    A.REMEDIAL_ACTION_DATE2,
    A.CA_DATE2,
    A.CAC_DATE2,
    A.PA_DATE2,
    A.PAC_DATE2
    from
    westgarth.cis_report_4_details A';
    IF :P9_DEPARTMENT != '-1'
         THEN
         IF we = 'Y'
              THEN
                   w := w || ' AND A.ACTION_DEPARTMENT = :P9_DEPARTMENT';
              ELSE
                   w := ' A.ACTION_DEPARTMENT = :P9_DEPARTMENT';
                   we := 'Y';
         END IF;
    END IF;
    IF :P9_ACTION_BY != '-1'
         THEN
         IF we = 'Y'
              THEN
                   w := w || ' AND A.ACTION_BY = :P9_ACTION_BY';
              ELSE
                   w := ' A.ACTION_BY = :P9_ACTION_BY';
                   we := 'Y';
         END IF;
    END IF;
    IF (:P9_FROM != 'DD-MMM-YY' or :P9_FROM !='') AND (:P9_TO != 'DD-MMM-YY' or :P9_TO !='')
         THEN
         IF we = 'Y'
              THEN
                   w := w || ' AND A.REMEDIAL_ACTION_DATE2
    BETWEEN :P9_FROM AND :P9_TO';
              ELSE
                   w := ' A.REMEDIAL_ACTION_DATE2 BETWEEN :P9_FROM AND :P9_TO ';
                   we := 'Y';
         END IF;
    END IF;
    IF :P9_OVERDUE_ITEMS !='0'
         THEN
         If we = 'Y'
              THEN
                   W := W || ' AND SYSDATE > A.REMEDIAL_ACTION_DATE2';
              ELSE
                   W := ' SYSDATE > A.REMEDIAL_ACTION_DATE2';
                   we := 'Y';
         END IF;
    END IF;
    IF we = 'Y'
         THEN q := q || ' WHERE '|| w;
    END IF;
    --wwv_flow.debug(' query is:' || q);
    RETURN q;
    end if;
    END;

    Are you missing an ODBC / TNS entry on your CMS (or report processing, if clustered env) server?  This could definately be an issue if the report will run locally within CR client, but not when hosted on the enterprise environment.  Another test would be to run the report from CR client ON the CRS / BOE server..

  • Problem to run the Crystal report inside from SAP B1 based on SQL views.

    Hello,
    I have a problem to run my Crystal report inside from SAP B1 which is based on SQL views.And the SQL views are stored in a separate database in SQL server.The error which i am getting is saying the the tablename does not exist.What i need to do in order to sort this problem.
    Great if somebody can help me to sort out this so that i can run my report based on SQL views stored on separate database other than SAP databases inside from SAP B1.
    Edited by: rozenagrawal on Apr 19, 2011 11:51 AM

    Try using a SQL synonym in your company database for the views outside the company database. I don't know if SBO will let you get away with it, but its worth a shot.
    If your company database is MyCompany and you have a view called MyView in Views database, assuming the view belongs to schema dbo, and you want the synonym to belong to dbo schema in your company database, run this:
    Use MyCompany
    go
    create synonym dbo.OutsiderView for
    Views.dbo.MyView
    go
    select * from OutsiderView
    The select statement should return the contents of MyView in the Views database while you are connected to your MyCompany database.
    For more info, see the Books Online for MSSQL on topic synonym.
    You will need to change your CR options to include displaying synonyms along with tables, views, etc. You may also need to grant select to B1 users.
    Edited by: Cindy Lange on Apr 21, 2011 4:00 PM

  • Need a Little Help embedding a Hyper Link in Report  based on Dynamic SQL

    I am trying to have a column in my report link to a document on my network when the column in the report is clicked. I have a table that contains a row for each document I want to link to. The URL to the document is stored in a column named NDDL.DOC_LINK. I would like the text "Linked" to appear as the value in the report column and to be a hyper link to the document.
    The report is a "Classic Report" based on PLSQL retuning a SQL stament. I am on Apex version 4.2.1.00.08
    I have been fighting with the '''''' stuff and can not get it worked out. have pasted the line in question but I can not get it to display correctly so I am hoping someone can help out.
      q := q || '  NDDL.DOC_TITLE as FILE_NAME, ';
      q := q || '  NDDL.DOC_DESC, ';
      q := q || '  ''<a href="http:'' || NDDL.DOC_LINK || ''target="_blank"> </a>'' as LINKED , ';
      q := q || '  NDDL.MOD_DATE, '; 
    ...The # in the line above should be:
    {code}
    http:'' || NDDL.DOC_LINK || ''target="
    Thanks!
    Edited by: Sky13 on Mar 7, 2013 12:45 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    I anwered your email. The PL/SQL block is like this:
    /* Formatted on 2013/03/07 23:05 (Formatter Plus v4.8.8) */
    DECLARE
       q   VARCHAR2 (4000);
    BEGIN
       q := 'select * from ( ';
       q := q || 'select ';
       q := q || '  NDDC.NDDC_UID, ';
       q := q || '  NDDC.NDND_UID, ';
       q := q || '  NDDC.LSVL_DOC_CAT_UID, ';
       q := q || '  NDDC.DATE_POSTED, ';
       q := q || '  NDDC.CREATE_DATE, ';
       q := q || '  NDDC.CREATE_BY, ';
       q := q || '  NDDC.MOD_DATE, ';
       q := q || '  NDDC.MOD_BY, ';
       q := q || '  NDDC.MIME_TYPE, ';
       q := q || '  NDDC.FILE_NAME, ';
       q := q || '  NDDC.CHARACTER_SET, ';
       q := q || '  NDDC.BLOB_MOD_DATE, ';
       q := q || '  NULL as DOC_DESC, ';
       q := q || '  NULL as DOC_LINK, ';
       IF :p24_doc_contains IS NOT NULL
       THEN
          q := q || '  score(1) as SCORE ';
       ELSE
          q := q || ' NULL as SCORE ';
       END IF;
       q := q || 'from ';
       q := q || '  NDDC_NODE_DOC NDDC ';
       q := q || 'where ( ';
       q :=
             q
          || ' INSTR(UPPER(CREATE_BY),UPPER(NVL(:P24_SEARCH,CREATE_BY))) > 0  or ';
       q := q || ' INSTR(UPPER(MOD_BY),UPPER(NVL(:P24_SEARCH,MOD_BY))) > 0  or ';
       q :=
             q
          || ' INSTR(UPPER(MIME_TYPE),UPPER(NVL(:P24_SEARCH,MIME_TYPE))) > 0  or ';
       q := q || ' INSTR(UPPER(FILE_NAME),UPPER(NVL(:P24_SEARCH,FILE_NAME))) > 0 ';
       q := q || ') ';
       IF :p24_doc_contains IS NOT NULL
       THEN
          q := q || '  and CONTAINS(document, :P24_DOC_CONTAINS,1) > 0 ';
       END IF;
       q := q || 'union all ';
       q := q || 'select ';
       q := q || '  NULL as NDDC_UID, ';
       q := q || '  NDDL.NDND_UID, ';
       q := q || '  NDDL.LSVL_DOC_CAT_UID, ';
       q := q || '  NDDL.DATE_POSTED, ';
       q := q || '  NDDL.CREATE_DATE, ';
       q := q || '  NDDL.CREATE_BY, ';
       q := q || '  NDDL.MOD_DATE, ';
       q := q || '  NDDL.MOD_BY, ';
       q := q || '  NULL as MIME_TYPE, ';
       q := q || '  NDDL.DOC_TITLE as FILE_NAME, ';
       q := q || '  NULL as CHARACTER_SET, ';
       q := q || '  NDDL.MOD_DATE as BLOB_MD_DATE, ';
       q := q || '  NDDL.DOC_DESC, ';
       q :=
             q
          || '  ''<a href="http:'''
          || '||nddl.doc_link||'''
          || '-.htm" target="_blank"> </a>'' as DOC_LINK , ';
       q := q || '  NULL as SCORE ';
       q := q || 'from ';
       q := q || '  NDDL_NODE_DOC_LINK NDDL ';
       q := q || 'where ';
       q :=
          q
          || '  ( INSTR(UPPER(CREATE_BY),UPPER(NVL(:P24_SEARCH,CREATE_BY))) > 0 ';
       q := q || '  or INSTR(UPPER(MOD_BY),UPPER(NVL(:P24_SEARCH,MOD_BY))) > 0 ';
       q :=
             q
          || '  or INSTR(UPPER(DOC_TITLE),UPPER(NVL(:P24_SEARCH,DOC_TITLE))) > 0 ';
       q :=
             q
          || '  or INSTR(UPPER(DOC_DESC),UPPER(NVL(:P24_SEARCH,DOC_DESC))) > 0 ) ';
       q := q || '  ) ';
       --htp.p(q);
       DBMS_OUTPUT.put_line (q);
    END;Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://www.apress.com/9781430235125
    http://apex.oracle.com/pls/apex/f?p=31517:1
    http://www.amazon.de/Oracle-APEX-XE-Praxis/dp/3826655494
    -------------------------------------------------------------------

  • Reports based on PL/SQL Procedure/Function

    Hi all,
    After some serious Google and forum searches, it appears as if this is something that just isn't possible (or easy to do).
    I've been charged with creating an APEX application that displays reports. There are a series of Procedures that will be written to return a result set, updated to take into account some filters that a user would provide. The key here is that the report won't be displayed until AFTER a user inputs some filters on a form and hits a Submit button. The project requires this functionality - allowing the report to be displayed and THEN filtered using the APEX IR Control is not desired (not my decision).
    There doesn't seem to be an easy way to define a report in this manner. It appears that the query for a report query needs to be known ahead of time.
    So, with that setup - is there a way to define an APEX report based on the return result of a PL/SQL function? OR is there a way to define a report using a SQL Query that is built based on user inputs?
    Any help would be appreciated.
    - Pedro

    Hi,
    Check if this post help you.
    Dynamic html table
    And normal reports can be also created from select that function is returning.
    http://www.oracle.com/technology/products/database/application_express/howtos/dynamic_report.html
    Br, Jari
    Edit:
    Maybe useful
    http://www.apex-blog.com/oracle-apex/dynamic-report-regions-tutorial-32.html
    http://www.oracleapplicationexpress.com/2009/02/interactive-report-based-on-plsql.html
    Edited by: jarola on Sep 9, 2009 5:14 PM

  • How to trigger a report based on a event/stored proc or sql dts completion

    Post Author: Crystaldev
    CA Forum: Publishing
    I want to run/trigger a crystal report based on file existence or based on a stored proc/sql dts/a value present in a sql table. The way I want to do is schedule a crystal report in crystal enterprise and then run the report based on a event like file existence or based on a sql dts completion or a value existence in a sql table. We are using crystal reports v10.
    I am not sure how we can do this, any help is appreciated. Thanks.

    Hi
    When you click on View Data, at bottom click on Edit button
    It will prompt a connection details tab wherein you can view and modify the connections
    Nik

  • Generating an  html report based on table at sql 2005 db

    Hi
    I want to create an html report based on a table named inventory on sql server 2005 database.
    first code used to generate an output report
        try {
                // TODO add your handling code here:
                String s = "<html> <body> <table border=1><caption> Inventory Report </caption>";
                s += "<tr><td>Item_id<td>item_name<td>Existing quantity</td><tr><td>3<td>4<td> <td>";
                byte[] sb = s.getBytes();
                FileOutputStream fs = null;
                try {
                    fs = new FileOutputStream("D:\\Report\\Report.html");
                } catch (FileNotFoundException ex) {
                    Logger.getLogger(mileshframe.class.getName()).log(Level.SEVERE, null, ex);
                fs.write(sb);
                fs.close();
            } catch (IOException ex) {
                Logger.getLogger(mileshframe.class.getName()).log(Level.SEVERE, null, ex);
    Second jdbc  code for connection and select all records in the table
    try {
                Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                 con = DriverManager.getConnection("jdbc:odbc:MerchandiseCon","sa","sql123#");
                st = con.createStatement( );
    ResultSet rset=st.executeQuery("Select Item_code,Item_Name,item_cost,item_quantity  from Inventory");
         String s="";
    while(rset.next())
        s+=(rset.getString(1)+"\t\t"+rset.getString(2)+"\t"+rset.getString(3)+"\t"+rset.getString(4)+"\n");
          st.close();
                con.close();
         catch(ClassNotFoundException ex)
             ex.printStackTrace();
          catch(SQLException ex)
             ex.printStackTrace();
            }                             I want someone helps me to merge two codes into one code to generate an output html report.
    thanks in advance

    This is my trial but not the desired result ,it's displayed the title and a line only
        private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {                                        
            // TODO add your handling code here:
                          String s = "<html> <body> <table border=1> <caption>Report title</caption>";
                byte[] sb = s.getBytes();
                FileOutputStream fs = null;
                try {
                // TODO add your handling code here:
                try {
                    fs = new FileOutputStream("D:\\Report\\myeport.html");
                } catch (FileNotFoundException ex) {
                    Logger.getLogger(NewJFrame.class.getName()).log(Level.SEVERE, null, ex);
                fs.write(sb);
                fs.close();
            } catch (IOException ex) {
                Logger.getLogger(NewJFrame.class.getName()).log(Level.SEVERE, null, ex);
                try {
                Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                 con = DriverManager.getConnection("jdbc:odbc:MerchandiseCon","sa","sql123#");
                st = con.createStatement( );
    ResultSet rset=st.executeQuery("Select Item_code,Item_Name,item_cost,item_quantity  from Inventory");
    while(rset.next())
                   s+=("<tr><td>"+rset.getString("Item_Code")+"</td><td>"+rset.getString("Item_Name")+"</td><td>"+rset.getString("item_cost")+"</td><td>"+rset.getString("item_quantity")+"</td></tr>");
                try {
                // TODO add your handling code here:
                try {
                    fs = new FileOutputStream("D:\\Report\\myeport.html");
                } catch (FileNotFoundException ex) {
                    Logger.getLogger(NewJFrame.class.getName()).log(Level.SEVERE, null, ex);
                fs.write(sb);
                fs.close();
            } catch (IOException ex) {
                Logger.getLogger(NewJFrame.class.getName()).log(Level.SEVERE, null, ex);
         st.close();
                con.close();
         catch(ClassNotFoundException ex)
             ex.printStackTrace();
          catch(SQLException ex)
             ex.printStackTrace();
        }

  • Report based on a ITEM (which has SQL statement)

    Hi everyone,
    I have a created a form based on a table which has 1 column that stores SQL statement in the database.And i am displaying the SQL statement in TEXT AREA FILED.
    What i want to do is to create a report based on that SQL statement (Which is in the TEXT AREA field on the same page).I tried to create a report region with
    :P25_SQL_STATEMENT.But i am getting an error
    ----->invalid query, no select statement found.
    How can i do a report based on the item which has SQL query in it.
    Thanks
    phani
    .

    Hi Jkallman,
    Thanks for the reply.I have a (FORM WITH REPORT) on a table which has column of SQL_STMNT VARCHAR2(2000 BYTE) which takes the SQL statement entered from the FORM.
    1.I have a report which shows all the records in the above mention table on page 10
    2.If i hit the edit button in the report i go to page 11 which i have the FORM on the above mentioned table.In that form i have a field :P11_SQL_STMNT.
    3.I am trying to create a report on the same page 11 based on the SQL query of that :P11_SQL_STMNT.
    4.I did the follwoing steps
    --> create a region
    ----> report
    ---->sql report
    and entered the following code.
    begin
    return (:P11_SQL_STMNT);
    end;
    but it is giving me the error which i mentioned in the previous post.If u need any more details i can provide
    Thanks in advance
    phani

  • Report Column as link or normal text based on SQL result

    Hi all,
    I would like to achieve the following:
    I have a report based on a PL/SQL function returning SQL query.
    The first column contains an ID (i.e. a number)
    If this number is contained in a nother table.field this column in this row shall be a link to another page incl. item assignments.
    If this is not the case, it shall be displayed as normal text.
    Example:
    TABLE1.ID = 123456
    IF SELECT count(*) FROM TABLE2 WHERE ID = TABLE1.ID > 1 then
    show column as link
    ELSE
    show column as text
    ENDIF.
    Does anyone have a solution for this?
    Thanks and best regards.
    KMC

    Hi,
    You could achieve that by creating the HTML tags required in the SQL statement itself:
    SELECT ...
    CASE WHEN .... THEN '&lt;a href="f?p=....."&gt;'|| FIELDNAME || '&lt;/a&gt;' ELSE FIELDNAME END FIELDNAME,
    FROM ...Of course, this would mean that the column shouldn't be sortable by the user
    Andy

  • What is this message in report based on "return SQL"

    After changing some parameter value in one report based on "function return SQL body"", we get:
    Invalid set of rows requested, the source data of the report has been modified.
    reset pagination
    We get this notice without error....just link "reset pagination" (*http://server:port/pls/htmldb/f?p=100:203:2666560392386347:NO::RP) which leads to error:
    Error      No checksum was provided to show processing for a page that requires a checksum when one or more request, clear cache, or argument values are passed as parameters.
    Any help ?
    THX!
    Message was edited by:
    Funky

    Found out...
    Originaly one search field was POPUP LOV type. Later we change them to "Text Field", bud LOV definition remains ...regardles it points to LOV which was not in use now.
    When remove LOV reference and delete the definition ...all works like a charm...

  • Report based on plsql table type

    Is it possible crete a report (updatable) based on plsql table type?
    thank in advance
    Franco Galante

    Sorry for my cryptic question, i wanted to mean create a report based on a stored procedure
    function which return a plsql table type variable.
    This idea could give me the chance to work with variable (plsql table) instead of db table.
    hope i'm enough clear
    thank you again
    Franco Galante

Maybe you are looking for

  • Mulitiple Line Header creation in ALV

    Hi ALV Folks,    I am trying to display mulitple lines in the ALV column headings like below .Can any one help how can i do this using ALV . i need to show like Header-A  - Header-B------ hedA1 HedA2 HedA3 HedB1 HedB2 HedB3 dataA1 dataA2 dataA3 dataB

  • Backing Up to disk in SQL Server 2005 - New Implementation

    Hi There, My company are implementing SAP with SQL Server 2005.  I have the responsibility of creating the backup strategy.  We will not be using Tape Media to back up - all our backups are carried out to DISK (SAN). Please can anyone state the recom

  • How to adjust the size of the slide in keynote to 7.5 feet high x 3.1 feet wide?

    How to adjust the size of the slide in keynote to 7.5 feet high x 3.1 feet wide?

  • Stuck on booting up

    I restarted my computer and now it's stuck on the white screen with Apple logo and keeps doing the thinking/loading Process.

  • Fan problem after graphics upgrade in 8570w

    I swapped the graphics card in my HP 8570w laptop for an AMD Firepro m4000, and now the fan runs constatly. It doesn't appear to be overheating as it's often just blowing failry cool air.  I used CPUID HWMonitor to check the temperature of the CPU/GP