Extracting from a Database: Postgres

Hi,
I know that Postgres isn't a certified database by SAP BI. This means that i won't be able to use DB CONNECT to extract data from a Postgres Database.
I just want to confirm with you experts if this is case. If my assumption is correct, is there a work around that i can use in order for me to extract data from a Postgres Database?
Kindly advise.
Thanks,
Ramon

Hi Raj,
Thank you for this information. This will help solve my problem of extracting data from a Postgres Server. I have 2 final questions though:
1.  What is the advantage of UD connect over DB connect in terms of performance? I am thinking that since UD connect is a MYSLEF interface, all of the raw data is converted into flat file and is afterwrads loaded into the data repository of BW; hence making it more heavy and populated.
The work around i was thinking is mirror imaging all of the data into a certified database server, say DB2, and extract there instead using DB connect. This will of course be more expensive to maintain. But in terms of performance, would it be more optimal to choose this option?
2. Have you ever tried using UD connect to from a Postgres server in real life?
Thanks,
Ramon

Similar Messages

  • Data extraction from Oracle database

    Hello all,
    I have to extract data from legacy database tables. I need to apply a lot of conditions on data extraction using SQL statements for getting only valid master data, transaction data, SAP date format etc. Unfortunately I don;t have a luxary of accessing legacy system data base table to create table views and applying select statements.
    Is there anyother way round by which I can filter data on source system side w/o getting into legacy system. I mean being in BW data source side.
    I am suppose to use both UD connect and DB connect to test which will workout better way of data extraction. But my question above should be same in either interface.
    This is very urgent as we are in design phase.
    Points will be rewarded immediately.
    Thanks
    Message was edited by:
            Shail
    Message was edited by:
            Shail

    Well I and eveyone know that it can be done in BI.
    I apologize that I did not mention it in my question.
    I am looking for very specific answer, if there is any trick we can do on source system side from BI. Or where we can insert SQL statements in infopackage or data source.
    Thanks

  • Is it possible to view the data that is extracted from logical database.

    Hi ,
    i have a standard program(T-code F.38) that uses logical database.This program also uses fields groups to define the structure.
    Now my question how can i see the data that is been fetched from logical database?Is that possible?
    I need to do further modifications on this data.Please advice whether its possible?

    hi,
    one possibility is dat.  goto SLDB give ur ldb name and goto source code.
    u will get code.
    now see dat and by giving same conditions u can check data using se16.

  • NPD Metrics - how to extract from the database in a usable format

    Metrics for NPD activities and projects are stored in the database one row for each metric in each activity or project instance. If there are multiple metrics per activity instance, for example, extraction of those metrics yeilds only a list of metrics and values. I'd like to see it in more of a table style output. Can you provide some guidance on how to extract this from the DB using sql? Thx

    Here is the SQL that should help understand the structure. There are a few ways to pull this data in more of a column based approach. This should help you get started.
    select modml.baseName as MetricName, bases.name as Basis, ph.name as Phase,
    fy.name as FiscalYear, gl.Value as Value, UOM.ID as UOM, currml.Name as Currency
    from plmFieldExchangeGlobals gl
    inner join plmFieldExchangeDefinitions fed on fed.pkid = gl.FieldExchangeDefinitionPKID
    inner join plmFieldExchangeDefModels mod on mod.pkid = fed.fkFieldExchangeDefinitionModel
    inner join plmFieldExchDefinitionModelML modml on modml.fkFieldExchangeDefinitionModel = mod.pkid and modml.langID = 0
    inner join plmFieldExchangeBases bases on fed.fkFieldExchangeBasis = bases.pkid and bases.langID = 0
    inner join plmFieldExchangePhases ph on fed.fkFieldExchangePhase = ph.pkid and ph.langID = 0
    inner join plmFieldExchangeFiscalYears fy on fed.fkFieldExchangeFiscalYear = fy.pkid and fy.langID = 0
    left outer join UOM on UOM.pkid = mod.fkCommonUOM
    left outer join commonCurrenciesML currml on currml.fkCurrency = mod.fkCommonCurrency and currml.langID = 0
    where ProjectPKID = '320219992047-072a-4698-a553-de5ec124ff9c';
    Segal

  • When I use SSIS for extract from OLAP Database, then the error random occurred,Error Code = 0x80040E05

     I have tired for this!
    When I use SSIS for extract data from ssas, that means,I use mdx query.
    then random error occured.
    Hope some one can understand my poor English....
    And the Error Info show below.
    Code Snippet
    Error: 0xC0202009 at Data Flow Task - For Individual User Tech Points, OLE DB Source 1 1 [31]: SSIS Error Code DTS_E_OLEDBERROR.  An OLE DB error has occurred. Error code: 0x80040E05.
    An OLE DB record is available.  Source: "Microsoft OLE DB Provider for Analysis Services 2005"  Hresult: 0x00000001  Description: "Error Code = 0x80040E05, External Code = 0x00000000:.".
    Error: 0xC004701A at Data Flow Task - For Individual User Tech Points, DTS.Pipeline: component "OLE DB Source 1 1" (31) failed the pre-execute phase and returned error code 0xC0202009.

    I have had the same error on SQL2008 and now on SQL2012 SSIS, but have been able to eliminate / workaround.
    We have a Loop Container in our Control flow that contains a data-flow task with an MDX source. The MDX query for the data-flow source is dynamically built (via an expression) on each iteration of the Loop container (however it always returns the "same shaped"
    results - only the filters in the WHERE clause are different).
    We've found the error to be somewhat intermittent - sometimes the package will complete successfully, other times it will fail with the 0x80040E05 error at varying iterations thru the container loop.
    To alleviate the problem we setup the SQL Agent job-step for this package to re-try on failure for up to 5 retries - not an ideal workaround, but it helped to improve the success rate of the Job.
    We have no idea why this error is occurring or what is causing it, however it appears to be timing-related in some way and I have only seen the issue when using a SSAS OLE-DB data source with a dynamically generated MDX query. I have managed to virtually
    eliminate the error from occurring with a not ideal workaround in the SSIS package - no idea why this works/helps (hopefully Microsoft will be able to work it out and resolve the issue as it's been plaguing us since SQL2008 and is still here in SQL2012
    SP1...
    Workaround for MDX causing 0x80040E05 error:
    Within our loop container we have added a Script task with OnSuccess precedent constraint to the data-flow task that contains the dynamically generated MDX source query. The script task simply introduces a WAIT in the processing immediately after the
    data-flow task completes of about 5 seconds, before allowing SSIS to continue with the next iteration (e.g. System.Threading.Thread.Sleep(5000)).
    With this delay in place we have had much more stable SSIS package executions - dont know why, but that's what we havce observed. Also note that when we migrated to SQL2012 SSIS packages the 0x80040E05 error returned, however we were able to eliminate it
    once more by increasing the WAIT time to 10 seconds on this script task.
    Now waiting for 10 seconds is not an ideal solution / workaround to this problem - particularly when it is contained within a Loop Container (in our case it has added nearly 30 minutes of "WAIT time" to the package execution duration), however this workaround
    is better than having the package fail 80%+ of the time...
    regards,
    Piquet

  • How to extract data from oracle database directly in to bi7.0 (net weaver)

    how to extract data from oracle database directly in to bi7.0 (net weaver)? is it something do with EDI? can anybody explain me in detail?
    Thanks
    York

    You can use UDConnect to get from Oracle database in to BW
    <b>Data Transfer with UD Connect -</b>
    http://help.sap.com/saphelp_nw04/helpdata/en/78/ef1441a509064abee6ffd6f38278fd/content.htm
    <b>Prerequisites</b>
    You have installed the SAP WAS J2EE Engine with BI Java components.  You can find more information on this in the SAP BW installation guide on the SAP Service Marketplace at service.sap.com/instguides.
    Hope it Helps
    Chetan
    @CP..

  • Extracting Values of a Field from a Database Table in SAP ECC System

    Hi,
    I downloaded Extracting Values of a Field from a Database Table in SAP ECC System Using MII 12.0
    senario from sdn. I'm trying to do that senario in MII 12.05. But I have problem with section 6 in page 7 (you can supply senario from sdn)
    "6- Under the loop of Repeater, use action u2018Rowu2019 to append just the string part of the WA which will display only values for field u2018Batchu2019"
    I did not find WA elemen in Output element of Repeater_0
    How can I create WA element?
    Thanks.

    Cemil,
    Set up a SAP JCo Interface action block.  Use the RFC name RFC_READ_TABLE.
    In the link editor map the table to "MARA", set RowCount to something small (20 is good sample size) and create an xml transaction property named FIELDS and copy the following into it:
    <?xml version="1.0" encoding="UTF-8"?><FIELDS>
          <item>
            <FIELDNAME>MATNR</FIELDNAME>
            <OFFSET/>
            <LENGTH/>
            <TYPE/>
            <FIELDTEXT/>
          </item>
          <item>
            <FIELDNAME>MTART</FIELDNAME>
            <OFFSET/>
            <LENGTH/>
            <TYPE/>
            <FIELDTEXT/>
          </item>
          <item>
            <FIELDNAME>BSTME</FIELDNAME>
            <OFFSET/>
            <LENGTH/>
            <TYPE/>
            <FIELDTEXT/>
          </item>
          <item>
            <FIELDNAME>XCHPF</FIELDNAME>
            <OFFSET/>
            <LENGTH/>
            <TYPE/>
            <FIELDTEXT/>
          </item>
          <item>
            <FIELDNAME>DATAB</FIELDNAME>
            <OFFSET/>
            <LENGTH/>
            <TYPE/>
            <FIELDTEXT/>
          </item>
        </FIELDS>
    Then link the Transaction.FIELDS to SAP_JCo_Interface_0.Request{/RFC_READ_TABLE/TABLES/FIELDS}.  You may run into problems with two other fields and optionally they can be removed (set link type to remove xml).  I usually remove them initially for testing.  The two fields are:
    SAP_JCo_Interface_0.Request{/RFC_READ_TABLE/INPUT/NO_DATA}
    SAP_JCo_Interface_0.Request{/RFC_READ_TABLE/INPUT/DELIMITER} (or you can set this to something like a semicolon,";" or tilda,"~".  I find it easier to caclulate position by length, but that is my own idiosyncrasy.)
    Once you get this one working, we can explore how to do filtering on the dataset.  Your output should be something like this:
    <?xml version="1.0" encoding="utf-8"?>
    <RFC_READ_TABLE>
      <INPUT>
        <DELIMITER />
        <NO_DATA />
        <QUERY_TABLE>MARA</QUERY_TABLE>
        <ROWCOUNT>20</ROWCOUNT>
        <ROWSKIPS>0</ROWSKIPS>
      </INPUT>
      <TABLES>
        <DATA>
          <item>
            <WA>000000000000000023ROH 00000000</WA>
          </item>
          <item>
            <WA>000000000000000038HALB 00000000</WA>
          </item>
          <item>
            <WA>000000000000000043HAWA 00000000</WA>
          </item>
          <item>
            <WA>000000000000000058HIBE 00000000</WA>
          </item>
          <item>
            <WA>000000000000000059HIBE 00000000</WA>
          </item>
          <item>
            <WA>000000000000000068FHMI 00000000</WA>
          </item>
          <item>
            <WA>000000000000000078DIEN 00000000</WA>
          </item>
          <item>
            <WA>000000000000000088FERT 00000000</WA>
          </item>
          <item>
            <WA>000000000000000089FERT 00000000</WA>
          </item>
          <item>
            <WA>000000000000000098HALB 00000000</WA>
          </item>
          <item>
            <WA>000000000000000170NLAG 00000000</WA>
          </item>
          <item>
            <WA>000000000000000178NLAG 00000000</WA>
          </item>
          <item>
            <WA>000000000000000188NLAG 00000000</WA>
          </item>
          <item>
            <WA>000000000000000288HALB 00000000</WA>
          </item>
          <item>
            <WA>000000000000000358HAWA 00000000</WA>
          </item>
          <item>
            <WA>000000000000000359HAWA 00000000</WA>
          </item>
          <item>
            <WA>000000000000000521HAWA 00000000</WA>
          </item>
          <item>
            <WA>000000000000000578FERT 00000000</WA>
          </item>
          <item>
            <WA>000000000000000597HAWA 00000000</WA>
          </item>
          <item>
            <WA>000000000000000598VERP 00000000</WA>
          </item>
        </DATA>
        <FIELDS>
          <item>
            <FIELDNAME>MATNR</FIELDNAME>
            <OFFSET>000000</OFFSET>
            <LENGTH>000018</LENGTH>
            <TYPE>C</TYPE>
            <FIELDTEXT>Material Number</FIELDTEXT>
          </item>
          <item>
            <FIELDNAME>MTART</FIELDNAME>
            <OFFSET>000018</OFFSET>
            <LENGTH>000004</LENGTH>
            <TYPE>C</TYPE>
            <FIELDTEXT>Material Type</FIELDTEXT>
          </item>
          <item>
            <FIELDNAME>BSTME</FIELDNAME>
            <OFFSET>000022</OFFSET>
            <LENGTH>000003</LENGTH>
            <TYPE>C</TYPE>
            <FIELDTEXT>Purchase Order Unit of Measure</FIELDTEXT>
          </item>
          <item>
            <FIELDNAME>XCHPF</FIELDNAME>
            <OFFSET>000025</OFFSET>
            <LENGTH>000001</LENGTH>
            <TYPE>C</TYPE>
            <FIELDTEXT>Batch management requirement indicator</FIELDTEXT>
          </item>
          <item>
            <FIELDNAME>DATAB</FIELDNAME>
            <OFFSET>000026</OFFSET>
            <LENGTH>000008</LENGTH>
            <TYPE>D</TYPE>
            <FIELDTEXT>Valid-From Date</FIELDTEXT>
          </item>
        </FIELDS>
        <OPTIONS />
      </TABLES>
    </RFC_READ_TABLE>
    Add a repeater sourced on:
    SAP_JCo_Interface_0.Response{/RFC_READ_TABLE/TABLES/DATA/item}
    Link your repeater output to a tracer with this:
    Repeater_0.Output{/item/WA}
    What you will see in each tracer message is a single line of data with all the fields contents concatenated together.  You can look up what each field in the string represents by the length of the field as returned in the Response segment of the RFC_READ_TABLE rfc.  Then you can parse out the data you are interested in.
    Give this a try and let me know how you succeeded.
    By the way, I could not find the scenario you referred to.  Can you post a link?
    Regards,
    Mike
    Edited by: Michael Appleby on Jan 12, 2009 5:16 PM

  • How to extract payload data from SOA database schema using Java

    I am trying to extract the payload data and output as XML text files using Java. Seems that is stored in SOA table XML_DOCUMENT. I am trying the following Java code to get started and it's not working as I would expect. I only get a few actual lines of output and, when I do, I only get the *<?xml version ... ?>* line.
    I appreciate any advice to extract the payload data from the database. Ultimately I will want to include the composite instance ID in the SQL but for now I'm just using the code shown here:
    OracleDataSource ods = new OracleDataSource();
    ods.setURL("soa_db_connection_string");
    ods.setUser("soa_db_user_id");
    ods.setPassword("soa_db_password");
    Connection conn = ods.getConnection();
    String sql = "select document from xml_document where rownum < 10";
    OraclePreparedStatement stmt = (OraclePreparedStatement)conn.prepareStatement(sql);
    DBBinXMLMetadataProvider dbrep = BinXMLMetadataProviderFactory.createDBMetadataProvider();
    dbrep.setConnectionPool(ods);
    dbrep.associateDataConnection(conn);
    OracleResultSet rset = (OracleResultSet)stmt.executeQuery();
    XMLDOMImplementation domimpl = new XMLDOMImplementation();
    BinXMLProcessor proc = BinXMLProcessorFactory.createProcessor(dbrep);
    while (rset.next()) {
         Blob blob = rset.getBlob("DOCUMENT");
         BinXMLStream inpbin = proc.createBinXMLStream(blob);
         BinXMLDecoder dec = inpbin.getDecoder();
         InfosetReader xmlreader = dec.getReader();
         XMLDocument doc = (XMLDocument)domimpl.createDocument(xmlreader);
         doc.print(System.out);
    }

    I found a method using a slight variation of the code I originally posted. Essentially you remove the DBBinXMLMetadataProvider dbrep portion. I believe, with this included, the XML being extracted is validated against the database (which is referenced as a "metadata provider"). Since the SOA schema doesn't seem to contain the information to validate the XML it returns as blank. If you don't include the dbrep portion then the XML is extracted as desired.
    OracleDataSource ods = new OracleDataSource();
    ods.setURL("soa_db_connection_string");
    ods.setUser("soa_db_user_id");
    ods.setPassword("soa_db_password");
    Connection conn = ods.getConnection();
    String sql = "select document from xml_document where rownum < 10";
    OraclePreparedStatement stmt = (OraclePreparedStatement)conn.prepareStatement(sql);
    OracleResultSet rset = (OracleResultSet)stmt.executeQuery();
    XMLDOMImplementation domimpl = new XMLDOMImplementation();
    BinXMLProcessor proc = BinXMLProcessorFactory.createProcessor();
    while (rset.next()) {
         BLOB blob = rset.getBLOB("DOCUMENT");
         BinXMLStream inpbin = proc.createBinXMLStream(blob);
         BinXMLDecoder dec = inpbin.getDecoder();
         InfosetReader xmlreader = dec.getReader();
         XMLDocument doc = (XMLDocument)domimpl.createDocument(xmlreader);
         doc.print(System.out);
    }

  • Can we extract blob objects from sql database to a human readable format?

    Hi All,
    I have question How can we extract
    blob objects from Sql database to human readable format ?
    Blob includes Images, text and docs.
    Thanks 
    Moug
    Best Regards Moug

    One thing you can do if its sql 2012 or later is to load the blob data to FileTable created in database. Then you would be able to physically browse to directory it points and see all files in its native format.
    see this for more details
    http://visakhm.blogspot.in/2012/07/working-with-filetables-in-sql-2012.html
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • Extract trigger DDL from 8i database

    Hi All,
    We are in process of migrating our 8i database's to 11g. for some reason , we excluded triggers while import. now , I need to get all the ddl's from 8i database.
    I think , dbms_metatadata is not there in 8i. using the following script did not help , as it does not append owner to trigger name. this script was taken from Mr Kyte book
    select
    'create or replace trigger ''' ||
    trigger_name || '''' || chr(10)||
    decode( substr( trigger_type, 1, 1 ),
    'A', 'AFTER', 'B', 'BEFORE', 'I', 'INSTEAD OF' ) ||
    chr(10) ||
    triggering_event || chr(10) ||
    'ON ''' || table_owner || '''.''' ||
    table_name || '' || chr(10) ||
    decode( instr( trigger_type, 'EACH ROW' ), 0, null,
    'FOR EACH ROW' ) || chr(10) ,
    trigger_body
    from dba_triggersRegards

    Thanks solomon, but , it still need some correction , I guess..
    create or replace trigger 'UFP"."UFP_TW_COST_AIUDR'
    AFTER
    INSERT OR UPDATE OR DELETE
    ON 'UFP'.'UFP_TGT_WKSHT_COST
    FOR EACH ROW
    DECLARE
       action_flag UFP.UFP_TGT_WKSHT_COST_AUDIT.ACTION%TYPE;
    BEGIN
       IF DELETING THEN
          insert into UFP.UFP_TGT_WKSHT_COST_AUDIT
             (PROJNO, REVNO, LINE_NUMBER, OPTION_NUMBER, COST, SKU_NUMBER, USERID,
             TIMESTAMP, ACTION)
             values
             (:old.PROJNO, :old.REVNO, :old.LINE_NUMBER, :old.OPTION_NUMBER, :old.COST, :old.SKU_NUMBER, USER,
             SYSDATE, 'DEL');
       ELSE
          IF INSERTING THEN
             action_flag := 'INS';
          ELSE
             action_flag := 'UPD';
          END IF;
          insert into UFP.UFP_TGT_WKSHT_COST_AUDIT
             (PROJNO, REVNO, LINE_NUMBER, OPTION_NUMBER, COST, SKU_NUMBER, USERID,
             TIMESTAMP, ACTION)
             values
             (:new.PROJNO, :new.REVNO, :new.LINE_NUMBER, :new.OPTION_NUMBER, :new.COST, :new.SKU_NUMBER, USER,
             SYSDATE, action_flag);
       END IF;
    END;
    create or replace trigger 'UFP"."UFP_TW_COST_AIUDR'
    ERROR at line 1:
    ORA-04070: invalid trigger name

  • How to move only subset of data from one database to another?

    Both source & destination are Oracle11g databases.
    The requirement details are as below,
    1) The database contains static as well as transactional data for telecom domain.
    2) We have to move region-wise data from one database to another.
    3) There are around 10 regions.
    4) The region wise data extraction from source db is based on around 40 to 50 tables. Rest of the tables contains
    static data & it will not change.
    5) The volume is around 1 million subscribers per region.
    6) The migration is required because
    a) The client is upgrading its base product which uses this database
    b) There is a change in structure of static tables
    c) Hardware upgrade
    d) The client want to start with single region on new database & rest of the regions will be operated from old
    database.
    7) Keep execution time to very minimum.
    I am thinking to have solution as below,
    1) Create destination database with upgraded db structure (as mentioned in 6b)
    2) Create database links to access source db in destination db.
    3) Write SQL queries to fetch data from all the respective tables for a specific region
    4) Write separate PL/SQL blocks for each table to fetch data from source db & insert into respective table in
    destination db
    a) Use FOR ALL & bulk collect to improve the performance
    b) Divide table data into multiple chunks & execute parallel batches (around 10) to insert the data
    5) Validate pre & post counts to verify the success of migration
    Is there any other better way?
    Regards,
    Sandeep

    How to move only subset of data from a partiular table by using transportable tablespace?
    E.g. SUB table using SMP_SUB tablespace contains subscriber data in source database.
    The indexes defined on SUB table are under SMP_IDX_SUB tablespace
    The subscribers data can be categorized by different regions, say region_id column. Then how to move data & indexes of SUB table from source db to destination db?
    any specific example would be helpful.

  • How can i  get data from anather database system  ????????

    Hi every body..
    I 've a problem .....
    I've an old program work on "DOS" and it's content database which content all Data that i need for that program
    The data file extension with ".FD" , ".VW" , ".LSS" & "SLP"
    I want to kow:-
    1) what is that database system
    2)What program could open or can get data from that database tables.
    3)can i do that with oracle...
    please describe every thing in details...
    ... Please replay quickly... urgently
    ...waiting your answer....

    You're probably better off consulting the documentation for the DOS program you're trying to deal with than hoping someone here will be able to guess what program you're using, identify the structure of the files, and tell you how to extract the data into something Oracle can import.
    Justin

  • Displaying Word Document from a Database

    Let me try to explain this.
    I can upload and store a Word Document in an Oracle database
    (BLOB column) but now I need to extract that Word document and
    place a pointer to it on the Web. Can someone explain to me how
    this is done?
    I'm trying to do something like have an image displayed on
    the Web and when you click on it the Word Document is opened.
    Follow me on that? So, if there are 15 Word documents in the
    database, then the web page would have 15 images all pointing to
    each separate Word document.
    Has anyone done this?

    Don't take my word on this, but I think this should work;
    I've done this in the past to send dynamically-generated CSV files
    to the user, which is in a way (at least at the perspective of
    what's being outputted to the user) the same thing.
    First, obviously, you need to retrieve the Word document data
    from the database. We'll say you put that in a variable called
    'wordDoc'.
    <cfset wordDoc = someQuery.wordDataObj />
    Next, we need to set the 'Content-disposition' HTTP header,
    to tell the client's browser that we're sending a file, and that we
    want you to call it somefile.doc by default. We'll do this with the
    <cfheader> tag (note that if you use <cfflush> in the
    application, this tag (and thus, this approach)
    will not work.
    <cfheader name="Content-disposition" value="attachment;
    filename=somefile.doc" />
    Almost there. Now we need to set the Content-type HTTP
    header, to tell the browser what kind of data is coming, and then
    give it the actual file data. We'll use the <cfcontent> tag
    to do both of these things.
    <cfcontent type="application/msword"
    reset="yes">#wordDoc#</cfcontent><cfabort>
    If memory serves, this should be all you need. Note the
    <cfabort> after the closing <cfcontent> tag, I've had
    problems in the past with additional output on the page after these
    tags being appended to what gets sent to the browser, so I use a
    <cfabort> afterwards to make sure nothing more gets sent
    after the data we want. Also, at least with CFMX7, I've noticed
    that debugging output tends to get added in too regardless, so I
    typically put a <cfsetting showdebugoutput="false" /> at the
    top of the file, too.
    I can't guarantee this will work, I haven't tested this
    particular situation, but if it doesn't, it ought to be close. Let
    me know if I'm wrong.
    Attached is what should be the code without my commentary /
    rambling interspersed.

  • How to read data from SAP database in java?

    Hi All ,
    I want to read some tables from SAP database in java? How to connect to SAP database in java.I want to read the data from SAP NetWeaver BW 7.3.
    Please help..

    Download Vder [http://binhgiang.sourceforge.net/site/download.jsp|http://binhgiang.sourceforge.net/site/download.jsp]
    Extract date from website, output to xml format then save to database (MySQL, Oracle,...)
    Screenshot: [http://binhgiang.sourceforge.net/xmlalbum/screenshots.html|http://binhgiang.sourceforge.net/xmlalbum/screenshots.html]
    Edited by: Nhu_Dinh_Thuan on Jul 23, 2009 9:55 PM
    Edited by: Nhu_Dinh_Thuan on Jul 23, 2009 9:56 PM

  • Viewing a PDF from the database

    Ok I am now finally down to the last thing that I need to get working on my program, at least for the time being. I am still doing research trying to find out how to do it but so far it has been unsuccessful, I am trying to make it so that the user can select a file on the database and then display that file in PDF form (the file is already in PDF) and then once it is displayed they can do whatever with it. I've already got the selecting the file taken care of now I'm just trying to figure out how to get the selected file to display on the screen.

    is there a way to download the file to a temp folder on the app server and then display it from thereIn order to write your file from the Database Server (DS) to the Application Server (AS) you will have either have the DS and AS be the same server or you will have a shared drive that is accessible from both servers. I personally like the use of shared drives. The reason for this is that the RDMBS can only read/write to the file system of the DS; conversly, the AS can only read/write to the file system of the AS. With a shared drive (Mount Point) the AS and DS can write to the same directory.
    So the question now is how to extract the file from the database to the filesystem. If you have access to My Oracle Support (MOS) look up *How to Write BLOBs Stored Inside the Database Out to Files [Doc ID: 330146.1]*. If you don't have access to MOS let me know and I'll post the code from this document. Basically you create a procedure that uses the DBMS_LOB package to read the file form your table in chunks and then writes these chunks of the file to the file system using the UTL_FILE package. When you write the file to the file system, you write it to the shared drive. The shared drive must be accessable by the AS processes on the AS. Then in your form you could server the file to the user with a simple WEB.SHOW_DOCUMENT() call. The file will be delivered to the user via the Browser and the user will have the choice of saving or viewing the file. You will need to work with your DS and AS admins to set things up on your servers. I also recommend you built a process on the AS that will routinely delete the files in this shared drive to prevent accidently serving up an old copy of a file and to eliminate stale files on the shared drive.
    Hope this helps,
    Craig B-)
    If someone's response is helpful or correct, please mark it accordingly.

Maybe you are looking for