Download BW Query results in HTML format

On a daily basis, I need to get BW query results exported to an HTML extract file on the BW server.  The HTML file will then be transferred to a Windows server for use in a dashboard view by a third party developed portal.  The query has an input variable for period.
What is the best/simplest method for scheduling an existing BW query to run on a daily basis to produce an HTML  extract / download file to the BW server file system?
We are currently on BW 7.01 SP6.  We just completed a technical upgrade from BW3.5, but did not do a functional upgrade.
I have read through many postings but have been unable to find a solution.  I have reviewed RSCRM_BAPI u2013 no html format.
Any help would be greatly appreciated.
Thanks,
Mark Norton

Hello Mark...
Amer is right. You can create a broadcast setting to daily sends your
query as MHTML format.
You can send to your e-mail but there is a possibility to save on KM and CM repository.
There is a little explanation on the link below:
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/5c6b686a-0901-0010-8aab-c4d0e5a093a7?quicklink=index&overridelayout=true
To create a broadcast setting, open the query via Query Designer.
Click "Query" -> "Publish" -> "BEx Broadcaster"
While you are creating the broadcast, there is a "Output Format" option.
There is MHTML.
I hope you find this information useful.
Thanks
Edward

Similar Messages

  • Output query result in XML format

    folks:
    could anybody provide more information
    about how to generate query result in
    xml format? looks like DBXML is for demo only
    and i have heard that PLSQL XML parser is the way to go; so far i have not found
    a sample yet on how to actually
    do the XML generation; if you know more
    about it, please let me know; thanks in
    advance.
    Bill

    Here are some sample apps that might interest you:
    [list]
    [*][url [URL=http://technet.oracle.com/tech/xml/xsql_servlet/index2.htm?Code&files/ffhome.html]The]http://technet.oracle.com/tech/xml/xsql_servlet/index2.htm?Code&files/ffhome.html]The XML Flight Finder
    [*][url [URL=http://technet.oracle.com/sample_code/tech/xml/xmlb2b/doc/xb2bhome.html]B2B]http://technet.oracle.com/sample_code/tech/xml/xmlb2b/doc/xb2bhome.html]B2B with XML
    [list]
    Enjoy,
    -rh

  • Sending query result as html email

    hi,
    I have requirement to send query result as html emial to user, is there a possibility to send it?
    database is 11.2.3
    thanks,
    7Z

    Google is your friend
    http://oracle-base.com/articles/misc/email-from-oracle-plsql.php
    https://www.google.nl/search?q=send+email+oracle+database+11g

  • Send BW query results as HTML email from ABAP program

    I have published a code sample for sending BW query results as HTML email from ABAP program. if you have any questions or clarification, please post them here.
    the same can be accessed from this link.
    http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/b7658119-0a01-0010-39a9-b600c816f370
    Regards
    Raja
    Message was edited by: Durairaj Athavan Raja

    OK forget about my earlier post.
    do the following changes.
    declare the following variables:
    data: xtext type standard table of solix .
    DATA: atta_sub TYPE sood-objdes .
    after the call of FM SCMS_STRING_TO_FTEXT add the following code.
    CALL FUNCTION 'SO_SOLITAB_TO_SOLIXTAB'
      EXPORTING
        ip_solitab        = text
    IMPORTING
       EP_SOLIXTAB       = xtext .
    and after the following statement
    document = cl_document_bcs=>create_document(
                              i_type    = 'HTM'
                              i_text    = text
                              i_length  = conlengths
                              i_subject = subject ).
    add the following code
    CALL METHOD document->add_attachment
                EXPORTING
                  i_attachment_type    = 'htm'
                  i_attachment_subject = atta_sub
                  i_att_content_hex    = xtext.
    now you will have results both in the body as well as attachment. (this is for test you can remove one of them )
    Regards
    Raja

  • Broadcasting the precalculated query results in web format

    Hi Experts,
    We have a requirement  where we need to broadcast the precalculated query results in web format, we know that we can do this through workbook, but we want to do it in web format to avoid the limitations of the workbook like number of rows in workbook limited to 65000 etc.,
    We are using 3.x environment,
    please suggest that is this functionality can be achievable, if yes how?
    Thanks in advance,
    -Vinay

    Hi All, this problem was resolved.
    Thanks,
    vinay

  • How to pass query result to HTML table?

    Hi,
      i want to get the query result in HTMl table instead of Display Grid. how to do it? i searched in help, it suggests use icommand to do this. but i dont know how to pass the select query result to HTML table.. please help me.
    -senthil

    Hi Senthil,
    You can create an icommand query. You can then use the icommand retrieval methods to capture and manipulate the query data.
    (http://help.sap.com/saphelp_xmii115/helpdata/en/Applet_Reference_Details/iCom
    mand_Reference.htm)
    Basically what we did was, use the getColumnCount() and getRowCount() methods, once you have these two numbers you can set two for loops and use String getValue(int ColID, int RowID) , within the for loops you can generate the inner html content and write the values either in a html table or html form (which is what we did). This seems to work well, I'm still playing around with it and may post this approach on sdn by end of this week.
    Mahwish

  • Returning query results in XML format

    Besides using custom tag library, does anyone know any methods or techniques that i can retrive the query results from database in XML format. for example, i have a table named student in database like this:
    StudentNo  Name   Gender  Degree
    123       Tony    male    B.Comp.Sci.
    456       Tom     male    B.Fiance
    343       Mary    female  B.Accountingso, if i have query select * from table student, i would get someting like the following:
    <row>
    <studentNo>123</studentNo>
    <name>Tony</name>
    <Gender>male</Gender>
    <Degree>B.Comp.Sci</Degree>
    </row>
    <row>
    <studentNo>456</studentNo>
    <name>Tom</name>
    <Gender>male</Gender>
    <Degree>B.Finace</Degree>
    </row>
    The reason i am asking for this is i need query results returned in XML format, so i can wrap XSLT tag around, and apply for HTML, WML, and XHTML template resprectively so i can display them on different terminals. any help is appreciated.

    I have this method in a ResultSetMapper class:
         * Return result sets as an XML stream, with root tag named
         * "results", one "result" tag per row, and "result" child tag
         * names equal to the column name
         * @param query result set
         * @param list of column names to include in the result map
         * @throws SQLException if the query fails
         * @throws JDOMException if the XML stream creation fails
        public static final Document toJDOM(ResultSet rs, List wantedColumnNames)
            throws SQLException, JDOMException
            Element rows         = new Element("results");
            int numWantedColumns = wantedColumnNames.size();
            while (rs.next())
                Element row = new Element("result");
                for (int i = 0; i < numWantedColumns; ++i)
                    String columnName   = (String)wantedColumnNames.get(i);
                    Object value = rs.getObject(columnName);
                    row.addContent(new Element(columnName).setText(value.toString()));
                rows.addContent(row);
            return new Document(rows);
        }It uses JDOM from www.jdom.org. - MOD

  • SQL Developer 4.0 EA3. query result in export format problem

    Query output in export format (insert, csv, xml,...) is not working in 4.0 EA3.
    Query executed as script (F5) does not display anything:
    select /*insert*/ * from dual;
    SQL Developer 3 displays the result correctly:
    REM INSERTING into dual
    SET DEFINE OFF;
    Insert into "dual" (DUMMY) values ('X');
    About
    Oracle SQL Developer 4.0.0.13
    Version 4.0.0.13
    Build MAIN-13.30
    IDE Version: 12.1.3.0.41.131007.2031
    Product ID: oracle.sqldeveloper
    Product Version: 12.2.0.13.30
    Version
    Component    Version
    =========    =======
    Oracle IDE    4.0.0.13.30
    Java(TM) Platform    1.7.0_07
    Versioning Support    4.0.0.13.30

    That's been fixed for the next release.

  • Query results to HTML table

    I'm looking for a more efficient way to convert a query result into an HTML table so that I can paste it into an email. The procedure in sqldeveloper (version 3.1.07) is just too clunky and involves too many keystrokes and mouse clicks. And you can't save the HTML to the clipboard. (I'm talking about the "Export..." action here.)
    Am I missing something? Are there any alternatives?
    Thanks!

    ... but sqlplus is so last millenium....
    Seriously? I'm from the last millennium too, nevertheless I don't consider myself out of date
    SQL*PLUS is still my first choice when I have to run a script. I'ts behaviour is reliably the same whereever my script is executed. I would never trust a script that needs another tool to be executed.
    Generating a HTML-mail is IMHO out of scope for a database tool. It's a feature I would expect in a BI tool that specializes on reporting.
    Regards
    Marcus

  • Presenting Query results as HTML

    Hello,
    We currently have an application server logging into oracle. Currently the application pulls 2000 rows and then converts them into html formatted text. Is there a better way to this than having to first pull the 2000 rows into weblogic and then converting them into a table.
    Thanks.

    OK forget about my earlier post.
    do the following changes.
    declare the following variables:
    data: xtext type standard table of solix .
    DATA: atta_sub TYPE sood-objdes .
    after the call of FM SCMS_STRING_TO_FTEXT add the following code.
    CALL FUNCTION 'SO_SOLITAB_TO_SOLIXTAB'
      EXPORTING
        ip_solitab        = text
    IMPORTING
       EP_SOLIXTAB       = xtext .
    and after the following statement
    document = cl_document_bcs=>create_document(
                              i_type    = 'HTM'
                              i_text    = text
                              i_length  = conlengths
                              i_subject = subject ).
    add the following code
    CALL METHOD document->add_attachment
                EXPORTING
                  i_attachment_type    = 'htm'
                  i_attachment_subject = atta_sub
                  i_att_content_hex    = xtext.
    now you will have results both in the body as well as attachment. (this is for test you can remove one of them )
    Regards
    Raja

  • XML query results in HTML form parameter

    Hi,
    I would like insert records from a query result (raw XML) into HTML form tags, using the XSL stylesheet. Here is the code I am trying to use, but obviously it is not working.
    <INPUT TYPE="hidden" NAME="te_hb_strdEntryId"
    VALUE="<xsl:value-of select="ID"/>">
    Are there any other options to put a result of a query in a hidden tag, using XSL?
    Any help will be appriciated.

    <INPUT TYPE="hidden" NAME="te_hb_strdEntryId"
    VALUE="<xsl:value-of select="ID"/>">
    The correct syntax would be:
    <INPUT TYPE="hidden" NAME="xxx">
    <xsl:attribute name="VALUE">
    <xsl:value-of select="ID"/>
    </xsl:attribute>
    however, there is a shortcut syntax
    when you are using XPath expressions
    in literal attribute values:
    XSLT attribute value templates. They are
    XPath expressions inside curly braces.
    So, you can achieve your desired result
    with the shorter form:
    <INPUT TYPE="hidden" NAME="xxx" VALUE="{ID}">
    as well.

  • Security Audit Log / Logging of downloads from query results?

    Hi everybody,
    our data protection team has raised the requirement to log all data downloads from our BW system. As far as I know, it is possible to log downloads in SAP GUI using Security Audit Log, but does this also cover "Export to Excel" functionality of query results executed in the portal? And what about execution of queries with BEx Analyzer? I doubt, if that tool would log this. Are there any other tools available to cover that requirement?
    Any comment and idea is welcome. Thanks in advance!
    Regards,
    Carsten

    If restricted to ALV I think it can be done, but even there... if the user executes it in background and mails or prints the spool request then the cat is out of the box...
    Moral of the story: Do not grant access if the user should not be able to see the data (regardless where they log on from).
    That you cannot monitor / log all (mass) download events is however a bit unfortunate, however once the data is outside of the system for those whom you do trust then you anyway need to train them not to park sensitive files on project or public file servers.
    IMO the main problem here is front-end computing tools (like Excel, etc) which the users feel more confortable with to analyze data than the server side analytics tools (e.g. in the ALV task bars, or even the BOBJ Dashboards which are very "user-sentric").
    In German it is known as "Bauern mentalität" (farmer mentality) which generally resides at the application surphase layer in the greater scheme of things:
    -> You do not eat anything you have not slaughtered yourself... 
    Specifically regarding tokenization, you can consider not displaying the data in the portal. If the user wants to display these fields they have to navigate in their own context into the backend system to retrieve the token and then only display individual values.
    --> A download of a list via the portal or BEX excludes these fields which the user can access, but not mass download.
    I think this is possible, but it will be a challenge depending on whether the fields support tockenization. Credit Card numbers as mentioned my Martin is fairly vanilla and already used.
    Custom fields&types, insufficiently critical elements and older programs will be a bigger challenge.
    Please provide more details, as the generic answers are not well take care of IMO. If you cannot provide mre details, then SDN discussions speculating on answers is not efficient either...
    Cheers,
    Julius

  • Row query results to column format

    I have a table as follows:
    DT | SN | Type | Value
    1/1/15 1:15 | 1 | HID | 123
    1/1/15 1:15 | 1 | VAL | 456
    1/2/15 1:15 | 1 | HID | 123
    1/2/15 1:15 | 1 | VAL | 111
    1/4/15 1:15 | 2 | HID | 222
    1/4/15 1:15 | 2 | VAL | 233
    1/5/15 1:15 | 3 | HID | 333
    1/5/15 1:15 | 3 | VAL | 344
    How to I construct a query in the below format...
    DT | SN | HID | VAL
    1/1/15 1:15 | 1 | 123 | 456
    1/2/15 1:15 | 1 | 123 | 111
    1/4/15 1:15 | 2 | 222 | 233
    1/5/15 1:15 | 3 | 333 | 344

    Hi engrforever,
    Use a PIVOT to do it. Modified the date values here:
    Create TABLE #TEMP1
    (DT datetime NULL,
    SN int NULL,
    [Type] varchar(12) NULL,
    Value int NULL
    INSERT INTO #temp1(DT, SN,Type,Value) VALUES (GETDATE()-4,1,'HID',123),
    (GETDATE()-4,1,'VAL',456),
    (GETDATE()-3,1,'HID',123),
    (GETDATE()-3,1,'VAL',111),
    (GETDATE()-2,1,'HID',222),
    (GETDATE()-2,1,'VAL',233)
    SELECT * FROM
    (SELECT DT,SN, TYPE, Value FROM #temp1) DT
    PIVOT
    ( SUM (VALUE)
    FOR TYPE IN ([HID],[VAL])
    ) PT
    DROP TABLE #TEMP1

  • Converting Query results into HTML email

    Hi,
    I am using oracle 11g. I' m using the following procedure to send out html emails from a static query in the procedure and it works fine. I wanted to make it dynamic and pass the sql query as a parameter to procedure and build the html tags based on the query. Any thoughts?
    CREATE OR REPLACE PROCEDURE html_sql_results
    is
        v_rows clob;
        v_header clob;
        cursor v_cursor is
        select SR_NO,STATE,DUE_DT,PROCESS_DT,STATUS,DAY_NO,SEQ_NO
        from T_TABLE;
        BEGIN
        v_header := '<table border=1>
                  <tr style=''background:#8DB3E2''>
                  <td><p><b>SR_NO</b></p></td>
                  <td><p><b>STATE</b></p></td>
                  <td><p><b>DUE_DT</b></p></td>
                  <td><p><b>PROCESS_DT</b></p></td>
                  <td><p><b>STATUS</b></p></td>
                  <td><p><b>DAY_NO</b></p></td>
                  <td><p><b>SEQ_NO</b></p></td>
                  </tr>';
        v_rows := Null;
        FOR i in v_cursor
        LOOP
        v_rows  := v_rows ||
                '<tr>
                <td> <p>' || I.SR_NO||'</p></td>
                <td> <p>' || I.STATE||'</p></td>
                <td> <p>' || I.DUE_DT ||'</p></td>
                <td> <p>' || I.PROCESS_DT ||'</p></td>
                <td> <p>' || I.STATUS||'</p></td>
                <td> <p>' || I.DAY_NO ||'</p></td>
                <td> <p>' || I.SEQ_NO||'</p></td>
                </tr> ';
        END LOOP;
        if v_rows is not null then
        v_rows:= v_header ||v_rows ||' </table> ' ;
        dbms_output.put_line(v_rows); 
        email_results(v_rows);
        end if ;
        end ;
    /

    A possible way :
    SQL> var result clob
    SQL> DECLARE
      2
      3    ctx  dbms_xmlgen.ctxHandle;
      4    qry  varchar2(2000) := 'SELECT * FROM hr.employees WHERE department_id = :1';
      5
      6    xsl  xmltype := xmltype('<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
      7   <xsl:output method="html"/>
      8   <xsl:template match="/ROWSET">
      9    <table border="1">
    10     <tr style="background:#8DB3E2">
    11      <xsl:for-each select="ROW[1]/*">
    12       <td><p><b><xsl:value-of select="name()"/></b></p></td>
    13      </xsl:for-each>
    14      <xsl:apply-templates/>
    15     </tr>
    16    </table>
    17   </xsl:template>
    18   <xsl:template match="ROW">
    19    <tr><xsl:apply-templates/></tr>
    20   </xsl:template>
    21   <xsl:template match="ROW/*">
    22    <td><p><b><xsl:value-of select="."/></b></p></td>
    23   </xsl:template>
    24  </xsl:stylesheet>');
    25
    26    res  clob;
    27
    28  BEGIN
    29
    30    ctx := dbms_xmlgen.newContext(qry);
    31    dbms_xmlgen.setBindValue(ctx, '1', 90);
    32    dbms_xmlgen.setNullHandling(ctx, dbms_xmlgen.EMPTY_TAG);
    33    dbms_xmlgen.setXSLT(ctx, xsl);
    34
    35    :result := dbms_xmlgen.getXML(ctx);
    36    dbms_xmlgen.closeContext(ctx);
    37
    38    --dbms_output.put_line(res);
    39
    40  END;
    41  /
    PL/SQL procedure successfully completed.
    SQL> print result
    RESULT
    <table border="1"><tr style="background:#8DB3E2"><td><p><b>EMPLOYEE_ID</b></p></
    td><td><p><b>FIRST_NAME</b></p></td><td><p><b>LAST_NAME</b></p></td><td><p><b>EM
    AIL</b></p></td><td><p><b>PHONE_NUMBER</b></p></td><td><p><b>HIRE_DATE</b></p></
    td><td><p><b>JOB_ID</b></p></td><td><p><b>SALARY</b></p></td><td><p><b>COMMISSIO
    N_PCT</b></p></td><td><p><b>MANAGER_ID</b></p></td><td><p><b>DEPARTMENT_ID</b></
    p></td><tr><td><p><b>100</b></p></td><td><p><b>Steven</b></p></td><td><p><b>King
    </b></p></td><td><p><b>SKING</b></p></td><td><p><b>515.123.4567</b></p></td><td>
    <p><b>17/06/03</b></p></td><td><p><b>AD_PRES</b></p></td><td><p><b>24000</b></p>
    </td><td><p><b></b></p></td><td><p><b></b></p></td><td><p><b>90</b></p></td></tr
    <tr><td><p><b>101</b></p></td><td><p><b>Neena</b></p></td><td><p><b>Kochhar</b></p></td><td><p><b>NKOCHHAR</b></p></td><td><p><b>515.123.4568</b></p></td><td><
    p><b>21/09/05</b></p></td><td><p><b>AD_VP</b></p></td><td><p><b>17000</b></p></t
    d><td><p><b></b></p></td><td><p><b>100</b></p></td><td><p><b>90</b></p></td></tr
    <tr><td><p><b>102</b></p></td><td><p><b>Lex</b></p></td><td><p><b>De Haan</b></p></td><td><p><b>LDEHAAN</b></p></td><td><p><b>515.123.4569</b></p></td><td><p><
    b>13/01/01</b></p></td><td><p><b>AD_VP</b></p></td><td><p><b>17000</b></p></td><
    td><p><b></b></p></td><td><p><b>100</b></p></td><td><p><b>90</b></p></td></tr></
    tr></table>Typically, XSLT stylesheets may be stored in the database too, so that you can modify and use different presentation templates without touching the code.

  • SQL query result with HTML Data in output

    Hello,
    I have a SQL table , in one column I store HTML data. I need to query the table and get the HTML data in the columns that have 'HREF'. The output shows as grid on the sql management studio, however when I export it to excel, the HTML data does not get copied
    correctly, since there are HTML tags etc.
    How can I export the report correctly from SQL ?

    Hello,
    The HTML data is stored in a column with datatype as nvarchar(max). Sample data in the column is shown below. It is with formatting etc and is rendered as is on the web page. the business wants to generate a quick report so that they can see the pages that
    have links displayed. I can do that by querying the columns that have a 'HREF' in the text.
    Can I get the exact HREF values using just sql query? There can be more than one links on a page.
    Also, If I just want to copy the whole column and paste it on excel, how can I do that? If I copy the data below and paste, it does not get copied in one cell.. it spreads across multiple cells, so the report does not make any sense.
    <br />
    <table border="0" cellpadding="0" cellspacing="0" style="width: 431pt; border-collapse: collapse;" width="574">
    <tbody>
    <tr height="19" style="height: 14.25pt; ">
    <td height="19" style="border: 0px blue; width: 431pt; height: 14.25pt; background-color: transparent;" width="574"><a href="https:"><u><font color="#0066cc" face="Calibri">ax </font></u></a></td>
    </tr>
    </tbody>
    <colgroup>
    <col style="width: 431pt; " width="574" />
    </colgroup>
    </table>

Maybe you are looking for