How to store data from a hashtable into textfile?

let say i have 10 data in a hashtable, how can i store these data to a textfile? thanks a lot

try to use Properties instead of HashTable,
it has an operation store(OutputStream out, String header)
using which we can write content of Properties to a file
Also load content of a file using load(InputStream inStream),
This is pretty simple operation.
Renjith.

Similar Messages

  • How to extract data from info cube into an internal table using ABAP code

    HI
    Can Anyone plz suggest me
    How to extract data from info cube into an internal table using ABAP code like BAPI's or function modules.
    Thankx in advance
    regds
    AJAY

    HI Dinesh,
    Thankq for ur reply
    but i ahve already tried to use the function module.
    When I try to Use the function module RSDRI_INFOPOV_READ
    I get an information message "ERROR GENERATION TEST FRAME".
    can U plz tell me what could be the problem
    Bye
    AJAY

  • How to store data from textfile to vector and delete a selected row.

    Can someone teach me how to store data from textfile to vector and delete a selected row. And after deleting, i want to write the changes in my textfile.
    Do someone has an idea? :)

    nemesisjava wrote:
    Can someone teach me how to store data from textfile to vector and delete a selected row. And after deleting, i want to write the changes in my textfile.
    Do someone has an idea? :)What's the problem? What have you done so far? What failed?
    What you described should be pretty easy to do.

  • Store data from a table into excel sheet and email

    Hi all,
    I am just wondering, i m not sure where to start. I want to insert data from a table into an excel spread sheet.
    I'm working on a stored procedure with 3 input parameters:
    1. the actual query
    2. userid
    3. the column headers (comma separated) - these will be in the same order as the outer select statement in the query itself. I will use the column headers for the respective columns in Excel worksheet.
    When the proc is executed, the excel is populated. If the record count is > 65536, then I need to create multiple worksheets in the same excel file.
    How can i do that? Can any body please help with this..?

    We are doing like this ( Not sure whether it is the best method available)
    --Get the output of the query (Since the number of columns is not fixed you would have to use dbms_sql package)
    --loop through the output and write into a file, for example test.csv, using UTL_FILE package
    --load the file into a blob variable(we are doing it by loading it into a table)
    --For mailing You can use the below package
    http://www.oracle.com/technology/sample_code/tech/pl_sql/htdocs/Utl_Smtp_Sample.html
    Mailing code we are using is given below:
    CREATE OR REPLACE procedure xls_mail(
        p_sender     varchar2, -- sender, example: 'Me <[email protected]>'
        p_recipients varchar2, -- recipients, example: 'Someone <[email protected]>'
        p_subject    varchar2, -- subject
         p_text           varchar2, -- text
         p_filename      varchar2, -- name of xls file
         p_blob           blob         -- xls file
    ) is
      conn      utl_smtp.connection;
      i number;
      len number;
    BEGIN
      conn := demo_mail.begin_mail(
        sender     => p_sender,
        recipients => p_recipients,
        subject    => p_subject,
        mime_type  => demo_mail.MULTIPART_MIME_TYPE);
      demo_mail.begin_attachment(
        conn         => conn,
        mime_type    => 'application/xls',
        inline       => TRUE,
        filename     => p_filename,
        transfer_enc => 'base64');
        -- split the Base64 encoded attachment into multiple lines
       i   := 1;
       len := DBMS_LOB.getLength(p_blob);
       WHILE (i < len) LOOP
          IF(i + demo_mail.MAX_BASE64_LINE_WIDTH < len)THEN
             UTL_SMTP.Write_Raw_Data (conn
                                    , UTL_ENCODE.Base64_Encode(
                                            DBMS_LOB.Substr(p_blob, demo_mail.MAX_BASE64_LINE_WIDTH, i)));
          ELSE
             UTL_SMTP.Write_Raw_Data (conn
                                    , UTL_ENCODE.Base64_Encode(
                                            DBMS_LOB.Substr(p_blob, (len - i)+1,  i)));
          END IF;
          UTL_SMTP.Write_Data(conn, UTL_TCP.CRLF);
          i := i + demo_mail.MAX_BASE64_LINE_WIDTH;
       END LOOP;
      demo_mail.end_attachment(conn => conn);
      demo_mail.attach_text(
        conn      => conn,
        data      => p_text,
        mime_type => 'text/html');
      demo_mail.end_mail( conn => conn );
    END;

  • How to store data from Host.vi in cRIO-9074

    TejasKumar Patel
    I implemented a advance Measurement and Control system using cRIO-9074
    with c-Series I/O cards( NI 9217, 9411, 9264)
    I have some questions about it,
    (1)- Data rate from FPGA targate to host vi is too low. how can I increase
    it, when I run my host VI, sometimes all temperature sensor update at
    same time and sometimes one by one, can you please give me some hint, how
    can I correct it, I used two FIFOs for NI-9411 digital pulses, I put all
    Digital input and all analog output and input in a seperate while loop in
    FPGA targate VI.
    (2)- I have to write that data to analyse for further result. I tried all
    possible way to write data including wite to spreadsheet.vi, write to
    text.vi, Data storage.vi, Write to measurement.vi. All this VI work
    efficientlywhen it run individualy, But when I connect this VI to
    writedata from FPGA host VI. than it always give empty file.
    I saw your post in NI discussion forum about how to write data from
    Host.vi, But still I am confuse that how can I creat a protocol between
    host VI and Fpga target vi. to write the data in a file. I have nearabout
    38 channel to write data.
    (3)- I have to measure time difference between two digital pulses, to find
    a flow rate. I am using counter for it with risisng edge shot.vi, but when
    i get a timestemp when there is risisng edge for the second rising edge
    how can I get timestemp. Its like i have to measure time between two
    pulses, I triend waveform measurement.vi to find cycle period. but it not
    worked. any other was to measure it.
    I am stuck in this question since from last one month. I already followed
    NI-discussion forum solution but it doesnt work. I think the way I applied
    is may be wrong. 
    Looking forward to hear from you soon.
    Plese send an additional email copy to [email protected]
    Thank you and Best Regards, 

    Thanks Joseph for your support,
    1-      If I count the ticks between the pulses it always seems different ….because this method I already tried, but it does not work,  like some times it shows 9099 tick and at the second pulse it shows like some more or less ticks not the same ticks every time. To complete my project, the biggest problem is the data storage.
    2-      As you gives the solution in NI forum, “low level file I/O Vis such as Write to text file” FPGA target not support this VI. And mainly I want to write data from HOST.vi, because I am process those data …and I need to store it. For to figure out my result.
    3-      If I use “Write to text file. VI (Sub-VI ) to FPGA.vi, it not support because it support string data and I have FIXpoint data. And can you explain me what is low level file IO, and how can I use in fpga.vi??
    4-      Yes, for my project time stamp it really necessary, for data analysis.
    5-      I need the time stamp to find out what was the system response at the time.  As our project based on weather temperature, I need time stamp.
    Waiting for your reply,
    Thanks and Regards,
    Patel

  • How to take data from HTML Template into BSP Variable?

    hi all,
                can we take the data from the input field of HTML Template and collect into BSP variable? i have the shown the HTML Template into BSP page by passing the url in <IFRAME> tag now i have to take the data form the into field of HTML Template and save it back to the BSP table onclicking the Save button of BSP Page. please help me out thanks in advance.
    Thanks & Regards,
    Amol

    Hi Amol,
    This is very simple....
    In the onInputProcessing event of the page use the following code to read data from the InputField into an ABAP variable...
    Then you can use it at will..!
    Code is :
    data : event       TYPE REF TO if_htmlb_data,
           but_event   TYPE REF TO cl_htmlb_event_button.
    event = cl_htmlb_manager=>get_event( request ).
    IF event->EVENT_NAME = 'button' and event->EVENT_TYPE = 'click'.
          but_event ?= event.
          CASE event->EVENT_ID.
            when 'your_button_id'.
              data : lw_inf type ref to cl_htmlb_inputfield.
                 lw_inf ?= cl_htmlb_manager=>get_data(
                                request = runtime->server->request
                                name    = 'inputField'
                                id      = 'your_inputField_id'  ).
              if lw_inf->value is not initial.
                lw_variable = lw_inf->value.
              endif.
         ENDCASE.
    ENDIF.

  • How to insert data from APEX form into two tables

    Hi,
    I'm running APEX 4.1 with Oracle XE 11g, having two tables CERTIFICATES and USER_FILES. Some of the (useless) fields are cut to reduce information:
    CREATE TABLE CERTIFICATES
    CERT_ID NUMBER NOT NULL ,
    CERT_OWNER NUMBER NOT NULL ,
    CERT_VENDOR NUMBER NOT NULL ,
    CERT_NAME VARCHAR2 (128) ,
    CERT_FILE NUMBER NOT NULL ,
    ) TABLESPACE CP_DATA
    LOGGING;
    ALTER TABLE CERTIFICATES
    ADD CONSTRAINT CERTIFICATES_PK PRIMARY KEY ( CERT_ID ) ;
    CREATE TABLE USER_FILES
    FILE_ID NUMBER NOT NULL ,
    FILENAME VARCHAR2 (128) ,
    BLOB_CONTENT BLOB ,
    MIMETYPE VARCHAR2 (32) ,
    LAST_UPDATE_DATE DATE
    ) TABLESPACE CP_FILES
    LOGGING
    LOB ( BLOB_CONTENT ) STORE AS SECUREFILE
    TABLESPACE CP_FILES
    STORAGE (
    PCTINCREASE 0
    MINEXTENTS 1
    MAXEXTENTS UNLIMITED
    FREELISTS 1
    BUFFER_POOL DEFAULT
    RETENTION
    ENABLE STORAGE IN ROW
    NOCACHE
    ALTER TABLE USER_FILES
    ADD CONSTRAINT CERT_FILES_PK PRIMARY KEY ( FILE_ID ) ;
    ALTER TABLE CERTIFICATES
    ADD CONSTRAINT CERTIFICATES_USER_FILES_FK FOREIGN KEY
    CERT_FILE
    REFERENCES USER_FILES
    FILE_ID
    NOT DEFERRABLE
    What I'm trying to do is to allow users to fill out all the certificate data and upload a file in an APEX form. Once submitted the file should be uploaded in the USER_FILES table and all the fields along with CERT_ID, which is the foreign key pointing to the file in the USER_FILES table to be populated to the CERTIFICATES table. APEX wizard forms are based on one table and I'm unable to build form on both tables.
    That's why I've created a view (V_CERT_FILES) on both tables and using INSTEAD OF trigger to insert/update both tables. I've done this before and updating this kind of views works perfect. Here is where the problem comes, if I'm updating the view all the data is updated correctly, but if I'm inserting into the view all the fields are populated at CERTIFICATES table, but for USER_FILES only the fields FILE_ID and LAST_UPDATE_DATE are populated. The rest three regarding the LOB are missing: BLOB_CONTENT, FILENAME, MIMETYPE. There are no errors when running this from APEX, but If I try to insert into the view from SQLDeveloper, I got this error:
    ORA-22816: unsupported feature with RETURNING clause
    ORA-06512: at line 1
    As far as I know RETURNING clause in not supported in INSTEAD of triggers, although I didn't have any RETURNING clauses in my trigger (body is below).
    Now the interesting stuff, after long tracing I found why this is happening:
    First, insert is executed and the BLOB along with all its properties are uploaded to wwv_flow_file_objects$.
    Then the following insert is executed to populate all the fields except the BLOB and it's properties, rowid is RETURNED, but as we know RETURNING clause is not supported in INSTEAD OF triggers, that's why I got error:
    PARSE ERROR #1918608720:len=266 dep=3 uid=48 oct=2 lid=48 tim=1324569863593494 err=22816
    INSERT INTO "SVE". "V_CERT_FILES" ( "CERT_ID", "CERT_OWNER", "CERT_VENDOR", "CERT_NAME", "BLOB_CONTENT") VALUES (:B1 ,:B2 ,:B3 ,:B4, ,EMPTY_BLOB()) RETURNING ROWID INTO :O0
    CLOSE #1918608720:c=0,e=11,dep=3,type=0,tim=1324569863593909
    EXEC #1820672032:c=3000,e=3168,p=0,cr=2,cu=4,mis=0,r=0,dep=2,og=1,plh=0,tim=1324569863593969
    ERROR #43:err=22816 tim=1324569863593993
    CLOSE #1820672032:c=0,e=43,dep=2,type=1,tim=1324569863594167
    Next my trigger gets in action, sequences are generated, CERTIFICATES table is populated and then USER_FILES, but only the FILE_ID and LAST_UPDATE_DATE.
    Finally update is fired against my view (V_CERT_FILES), reading data from wwv_flow_files it populates BLOB_CONTENT, MIMETYPE and FILENAME fields at the specific rowid in V_CERT_FILES, the one returned from the insert at the beginning. Last, file is deleted from wwv_flow_files.
    I'm using sequences for the primary keys, this is only the body of the INSTEAD OF trigger:
    select user_files_seq.nextval into l_file_id from dual;
    select certificates_seq.nextval into l_cert_id from dual;
    insert into user_files (file_id, filename, blob_content, mimetype, last_update_date) values (l_file_id, :n.filename, :n.blob_content, :n.mimetype, sysdate);
    insert into certificates (cert_id, cert_owner, cert_vendor, cert_name, cert_file) values (l_cert_id, :n.cert_owner, :n.cert_vendor, :n.cert_name, l_file_id);
    I'm surprised that I wasn't able to find a valuable source of information regarding this problem, only MOS note about running SQLoader against view with CLOB column and INSTEAD OF trigger. The solution would be to ran it against base table, MOS ID 795956.1.
    Maybe I'm missing something and that's why I decided to share my problem here. So my question is how do you create this kind of architecture, insert into two tables with a relation between them in APEX ? I read a lot in the Internet, some advices were for creating custom form with APEX API, create a custom ARP, create two ARP or create a PL/SQL procedure for handing the DML?
    Thanks in advance.
    Regards,
    Sve

    Thank you however I was wondering if there was an example available which uses EJB and persistence.

  • How to write data from planning folder into a planning cube in BPS

    Hi All,
    I have an issue in writing data from planning folder to planning cube.
    I updated the excel sheet in planning folder in UPSPL tcode.
    After clicking on save button in the excel sheet the data did not get updated into the cube.
    I set the real time cube to planning mode.
    Please let me know if there are any settings to save the data to cube or how can it be done.
    Thanks in advance.
    Regards,
    Lavanya.

    Hi Lavanya,
    What do you mean by "the data did not get updated into the cube" ?
    Don't you find a yellow request in the cube administration transaction ? What happened if you set it to green ?
    Regards,
    Fred

  • How to fetch data from different sources into one source (like into Ztable)

    hi friends,
    As per our client requirements they want to develope an Inventory and an Ontime delivery report in BO on top of Oracle database.
    Situation is some thing like they have ECC 6.0.and they want to collect all inventory and ontime delivery data at one place.According to me that could be one Ztable in which we can gather all data.Apart from that they are going to use Data Integrator in which they can directly fetch the data from R/3 system(They dont want to have BI system) and put all data in Oracle DB.On top of ORacle BO person can develop BO reports.
    My question is how to fetch all data at one place and what are the tables going to be use.
    kindly help me out as its very important project.
    Thanks
    Abhishek

    The following is my standard reply to those who need to get old data from a backup in one account and add it to another account.  The method described here may be applied to your case.  It would be a bit of a long process, though.
    When connected to the account you want to GET data from, Go to Settings>iCloud and turn all data that is syncing with iCloud (contacts, calendars, etc.) to Off. 
    When prompted choose to keep the data on the iPhone. 
    After everything is turned off, scroll to the bottom and tap Delete Account.  Next, set up a new iCloud account using a different Apple ID and turn iCloud data syncing for contacts, etc. back to On.  When prompted, choose Merge.  This will upload the data to this new account.
    Note that this only affects the "Apple data" like contacts, calendars, reminders, etc.  Many third party apps also use iCloud to store data files there.  These files may be lost in the process, unless the apps also keep the data locally on the device.
    NOTE:  Photos in the photo stream (if you use it) will not transfer to the new account.  It is advised that you save the photos to a computer before performing the account switch. 

  • Use transaction FILE to store data from a cube into a file with Open Hub

    Hi people:
    I'm using BI 7.0 .Mi requirement is to make a flat file using the information of a virtual cube. The file name must have the number of the month and the year. I know that this is possible through FILE transaction.
    Can anybody give me a clue how this transaction is used?Which are the steps in order to assemble the name of the file? Or is there any other option? I have defined the physical directory where the file must be leaved
    Any help will be great. Thanks in advanced

    Hi,
    pick up the code which you need from below.
    REPORT RSAN_WB_ROUTINE_TEMP_REPORT .
    TYPES: BEGIN OF y_source_fields ,
             /BIC/ZTO_ROUTE TYPE /BIC/OIZTO_ROUTE ,
             ZINT_HU__Z_WM_HU TYPE /BIC/OIZ_WM_HU ,
             CREATEDON TYPE /BI0/OICREATEDON ,
             ROUTE TYPE /BI0/OIROUTE ,
             PLANT TYPE /BI0/OIPLANT ,
             PLANT__0STREET TYPE /BI0/OISTREET ,
             PLANT__0CITY TYPE /BI0/OICITY ,
             PLANT__0REGION TYPE /BI0/OIREGION ,
             PLANT__0POSTAL_CD TYPE /BI0/OIPOSTAL_CD ,
             /BIC/ZRECVPLNT TYPE /BIC/OIZRECVPLNT ,
             ZRECVPLNT__0STREET TYPE /BI0/OISTREET ,
             ZRECVPLNT__0CITY TYPE /BI0/OICITY ,
             ZRECVPLNT__0REGION TYPE /BI0/OIREGION ,
             ZRECVPLNT__0POSTAL_CD TYPE /BI0/OIPOSTAL_CD ,
             KYF_0001 TYPE /BI0/OIDLV_QTY ,
             ROUTE__Z_CR_DOCK TYPE /BIC/OIZ_CR_DOCK ,
             REFER_DOC TYPE /BI0/OIREFER_DOC ,
           END OF y_source_fields .
    TYPES: yt_source_fields TYPE STANDARD TABLE OF y_source_fields .
    TYPES: BEGIN OF y_target_fields ,
             RECORDTYPE TYPE /BI0/OISTREET ,
             CONTAINER TYPE /BI0/OICITY ,
             /BIC/ZTO_ROUTE TYPE /BIC/OIZTO_ROUTE ,
             TRACKINGNUMBER TYPE /BIC/OIZ_WM_HU ,
             PO TYPE /BI0/OICITY ,
             STAGEDDATE TYPE /BI0/OICITY ,
             MOVEMENTTYPE TYPE /BI0/OICITY ,
             ROUTE TYPE /BI0/OIROUTE ,
             PLANT TYPE /BI0/OIPLANT ,
             PLANT__0STREET TYPE /BI0/OISTREET ,
             PLANT__0CITY TYPE /BI0/OICITY ,
             PLANT__0REGION TYPE /BI0/OIREGION ,
             PLANT__0POSTAL_CD TYPE /BI0/OIPOSTAL_CD ,
             ORIGINCONTACTNAME TYPE /BI0/OISTREET ,
             ORIGINCONTACTPHONE TYPE /BI0/OISTREET ,
             /BIC/ZRECVPLNT TYPE /BIC/OIZRECVPLNT ,
             ZRECVPLNT__0STREET TYPE /BI0/OISTREET ,
             ZRECVPLNT__0CITY TYPE /BI0/OISTREET ,
             ZRECVPLNT__0REGION TYPE /BI0/OISTREET ,
             ZRECVPLNT__0POSTAL_CD TYPE /BI0/OISTREET ,
             DESTINATIONCONTACTNAME TYPE /BI0/OISTREET ,
             DESTINATIONCONTACTPHONE TYPE /BI0/OISTREET ,
             RCCCODE TYPE /BI0/OISTREET ,
             GLCORCLLICODE TYPE /BI0/OISTREET ,
             JFCCODE TYPE /BI0/OISTREET ,
             DESCRIPTIONOFWORK1 TYPE /BI0/OISTREET ,
             DESCRIPTIONOFWORK2 TYPE /BI0/OISTREET ,
             INSTRUCTIONS TYPE /BI0/OISTREET ,
             REQUESTEDSHIPDATE TYPE /BI0/OICITY ,
             ROUTE__Z_CR_DOCK TYPE /BIC/OIZ_CR_DOCK ,
             REQUESTEDDELIVERYDATE TYPE /BI0/OICITY ,
             ATTSEORDER TYPE /BI0/OICITY ,
             CUBE TYPE /BI0/OISTREET ,
             WEIGHT TYPE /BI0/OISTREET ,
             PIECES TYPE /BI0/OIREFER_DOC ,
             REEL TYPE /BI0/OISTREET ,
             REELSIZE TYPE /BI0/OISTREET ,
             VENDORSKU TYPE /BI0/OISTREET ,
             ATTSESKU TYPE /BI0/OISTREET ,
             COMPANYNAME TYPE /BI0/OISTREET ,
             OEM TYPE /BI0/OISTREET ,
             REFER_DOC TYPE /BI0/OIREFER_DOC ,
             REFERENCENUMBER2 TYPE /BI0/OISTREET ,
             REFERENCENUMBER3 TYPE /BI0/OISTREET ,
             REFERENCENUMBER4 TYPE /BI0/OISTREET ,
           END OF y_target_fields .
    TYPES: yt_target_fields TYPE STANDARD TABLE OF y_target_fields .
    Begin of type definitions -
    *TYPES: ...
    End of type definitions -
    FORM compute_data_transformation
         USING     it_source TYPE yt_source_fields
                   ir_context TYPE REF TO if_rsan_rt_routine_context
         EXPORTING et_target TYPE yt_target_fields .
    Begin of transformation code -
      DATA: ls_source TYPE y_source_fields,
            ls_target TYPE y_target_fields,
            var1(10),
            var2(10),
            year(4),
            month(2),
            day(2),
            date(10),
            it_workdays type table of /bic/pzworkdays,
            wa_workdays type /bic/pzworkdays,
            sto_date(10),
            V_tabix TYPE sy-tabix,
            Y_tabix TYPE sy-tabix,
            sto_var1(10),
            sto_year(4),
            sto_month(2),
            sto_day(2),
            sto_final_date(10),
            W_HEADER LIKE LS_TARGET-RECORDTYPE,
            W_HEADER1(12) TYPE C VALUE 'HEDR00000000',
            W_FOOTER LIKE W_HEADER VALUE 'TRLR0000',
            CNT(5),
            CMD(125) TYPE C.
    **********CODE FOR GENRATING CSV FILE PATH*******************
    data: OUTFILE_NAME(100) TYPE C,
          OUTFILE_NAME1(10) TYPE C VALUE '/sapmnt/',
          OUTFILE_NAME3(18) TYPE C VALUE '/qoutsap/ATTUVS',
          DATE1 LIKE SY-DATUM,
          DD(2) TYPE C,
          MM(2) TYPE C,
          YYYY(4) TYPE C.
    MOVE SY-DATUM+6(2) TO DD.
    MOVE SY-DATUM+4(2) TO MM.
    MOVE SY-DATUM(4) TO YYYY.
    CONCATENATE YYYY MM DD INTO DATE1.
    CONCATENATE OUTFILE_NAME1 SY-SYSID OUTFILE_NAME3 '.CSV' INTO
    OUTFILE_NAME.
    **********END OF CODE FOR GENRATING CSV FILE PATH*************
      OPEN DATASET OUTFILE_NAME FOR OUTPUT IN TEXT MODE ENCODING DEFAULT.
    Code for generating Header.
      CONCATENATE W_HEADER1  SY-DATUM SY-UZEIT INTO W_HEADER.
      APPEND W_HEADER TO ET_TARGET.
      TRANSFER W_HEADER TO OUTFILE_NAME.
      CLEAR W_HEADER.
    End of code for generating Header.
    code for excluding the rows who's Quantity(PIECES) equal to zero.
      LOOP AT it_source INTO ls_source where KYF_0001 NE '0'.
    end of code for excluding the rows who's Quantity(PIECES) equal to
    *zero
        MOVE-CORRESPONDING ls_source TO ls_target.
        ls_target-RECORDTYPE = 'PKUP'.
        ls_target-CONTAINER = ''.
        ls_target-TRACKINGNUMBER = ls_source-ZINT_HU__Z_WM_HU.
        ls_target-PO = ''.
    Date Conversion for Staged Date.
        var1 = ls_source-CREATEDON.
        year = var1+0(4).
        month = var1+4(2).
        day = var1+6(2).
        CONCATENATE month '/' day '/' year INTO date.
    End of Date Conversion for Staged Date.
        ls_target-STAGEDDATE = date.
        ls_target-MOVEMENTTYPE = 'P'.
        ls_target-ORIGINCONTACTNAME = ''.
        ls_target-ORIGINCONTACTPHONE = ''.
        ls_target-DESTINATIONCONTACTNAME = ''.
        ls_target-DESTINATIONCONTACTPHONE = ''.
        ls_target-RCCCODE = ''.
        ls_target-GLCORCLLICODE = ''.
        ls_target-JFCCODE = ''.
        ls_target-DESCRIPTIONOFWORK1 = ''.
        ls_target-DESCRIPTIONOFWORK2 = ''.
        ls_target-INSTRUCTIONS = ''.
        ls_target-REQUESTEDSHIPDATE = date.
    Calculating STO Creation Date + 3 working Days.
        select /BIC/ZWORKDAYS from /bic/pzworkdays into table it_workdays.
        loop at it_workdays into wa_workdays.
            if  wa_workdays-/bic/zworkdays = ls_source-CREATEDON.
                V_tabix = sy-tabix.
                Y_tabix = V_tabix + 3.
            endif.
            If sy-tabix = y_tabix.
                sto_date = wa_workdays-/bic/zworkdays.
            endif.
        Endloop.
        clear v_tabix.
        clear Y_tabix.
        sto_var1 = sto_date.
        sto_year = sto_var1+0(4).
        sto_month = sto_var1+4(2).
        sto_day = sto_var1+6(2).
        CONCATENATE sto_month '/' sto_day '/' sto_year INTO sto_final_date.
    End Of Calculating STO Creation Date + 3 working Days.
        ls_target-REQUESTEDDELIVERYDATE = sto_final_date.
        ls_target-ATTSEORDER = ''.
        ls_target-CUBE = ''.
        ls_target-PIECES = ls_source-KYF_0001.
        ls_target-REEL = ''.
        ls_target-REELSIZE = ''.
        ls_target-VENDORSKU = ''.
        ls_target-ATTSESKU = ''.
        ls_target-COMPANYNAME = 'AT&T'.
        ls_target-OEM = ''.
        ls_target-REFERENCENUMBER2 = '0'.
        ls_target-REFERENCENUMBER3 = '0'.
        ls_target-REFERENCENUMBER4 = '0'.
        APPEND ls_target TO et_target.
        TRANSFER ls_target TO OUTFILE_NAME.
        CNT = CNT + 1.
      ENDLOOP.
        CNT = CNT + 2.
    Code for generating Header -Footer.
      SHIFT CNT LEFT DELETING LEADING SPACE.
      CONCATENATE W_FOOTER CNT INTO W_HEADER.
      APPEND W_HEADER TO ET_TARGET.
    End of code for generating Header -Footer.
    Code for file permissions
      TRANSFER W_HEADER TO OUTFILE_NAME.
      CLOSE DATASET OUTFILE_NAME.
      CONCATENATE 'chmod 644' OUTFILE_NAME INTO CMD SEPARATED BY SPACE.
      CALL 'SYSTEM' ID 'COMMAND' FIELD CMD.
    End of code for file permissions
    End of transformation code -
    ENDFORM.
    Hope it helps
    bhaskar

  • How to load data from XML DOM into tables using Business Components

    <p>
    Hi,
    </p>
    <p>
    I need to upload XML file (it&#39;s not a problem) an load data (DOM tree) from this file into relationan tables. This filelooks like this:
    </p>
    <p>
    <font face="courier new,courier" size="2">&lt;Departments&gt;
       &lt;Department&gt;
          &lt;DepartmentName&gt;OPERATIONS&lt;/DepartmentName&gt;
          &lt;Localization&gt;BOSTON&lt;/Localization&gt;
          &lt;Employees&gt;
             &lt;Employee&gt;
                &lt;LastName&gt;TURNER&lt;/LastName&gt;
                &lt;Job&gt;SALESMAN&lt;/Job&gt;
                &lt;Manager&gt;7698&lt;/Manager&gt;
                &lt;HireDate&gt;1981-09-08&lt;/HireDate&gt;
                &lt;Salary&gt;1500&lt;/Salary&gt;
                &lt;Commerce&gt;0&lt;/Commerce&gt;
             &lt;/Employee&gt;
          &lt;/Employees&gt;
       &lt;/Department&gt;
    &lt;/Departments&gt;</font>
    </p>
    <p>
    Is there any Business Components support to obtain this ? What about primary and foreign keys values (there is no in XML file). How to place this XML data in appropriate tables ?
    </p>
    <p>
    Kuba 
    </p>

    Pl post details of exact OS and database versions, along with a sample of the XML file and description of the tables. What have you tried so far ?
    http://docs.oracle.com/cd/E11882_01/server.112/e22490/ldr_control_file.htm#i1005614
    HTH
    Srini

  • How to store data from a complex query and only fresh hourly or daily?

    We have a report which runs quite slow (1-2 minutes) because the query is quite complicate, so we would like to run this query daily only and store in a table so for those procedures that need to use this complex query as a subquery, can just join to this table directly to get results.
    However, I am not sure what kind of object I should use to store data for this complex query. Is data in global temp table only persist within transaction? I need something that can persist the data and be access by procedures.
    Any suggestions are welcome,
    Cheers

    Thank you for your reply. I looked at the materialized view earlier on, but have some difficulties to use it. So I have some questions here:
    1.The complex query is not a sum or aggregate functions, it just need to get data from different tables based on different conditions, in this case is it still appropriate to use meterialized view?
    2.If it is, I created one, but how to use it in my procedure? From the articles I read, it seems I can't just query from this view directly. So do I need to keep the complex query in my procedure and how the procedure will use the meterialized view instead?
    3. I also put the complex query in a normal view, then create a materialized view for this normal view (I expect the data from the complex query will be cache here), then in the procedure I just select * from my_NormalView, but it takes the same time to run even when I set the QUERY_REWRITE_ENABLED to true in the alter session. So I am not sure what else I need to do to make sure the procedure use the materialized view instead of the normal view. Can I query from the Materialized View directly?
    Below in the code I copied from one of the article to create the materialized view based on my normal view:
    CREATE MATERIALIZED VIEW HK3ControlDB.MW_RIRating
    PCTFREE 5 PCTUSED 60
    TABLESPACE "USERS"
    STORAGE (INITIAL 50K NEXT 50K)
    USING INDEX STORAGE (INITIAL 25K NEXT 25K)
    REFRESH START WITH ROUND(SYSDATE + 1) + 11/24
    NEXT NEXT_DAY(TRUNC(SYSDATE), 'MONDAY') + 15/24
    enable query rewrite
    AS SELECT * FROM HK3ControlDB.VW_RIRating;
    Cheers

  • How to download Data from Database directly into excel

    I have a requirement to download very large quantity of data from database into Excel file.
    But condition is excel file should have only 65,536 rows in a single spread sheet(that's the limit i suppose),if i have more data points(rows) than it should be stored into different spreadsheet.......this continues so there can be many spread sheets in a single excel file.
    Data size can be 1 GB or more.
    Also specific naming conventions need to be followed for giving name to excel as well as different spread sheets in it.
    Please see if someone could help me out.

    Thanks for ur reply,
    But my requirement is to call "download to excel" method,in a java program on click by user for downloading an excel sheet on his machine.
    This is be done as part of a web application which is to be made (so can't open the excel first)

  • How to get data from maintaince view into internal table

    Hi,
    I want to get the all data from v_t179 (maintanence view) into intrenal table.
    if i write select stmt , it is giving error.
    I want all data into internal table.
    regards,
    Ajay

    I think this is what you want:
    TABLES: t179, t179t.
    DATA: v_t179_int TYPE TABLE OF v_t179.
    SELECT * FROM t179
      JOIN t179t ON
        t179~prodh = t179t~prodh
      INTO CORRESPONDING FIELDS OF TABLE v_t179_int.
    Rob

  • How to get data from MS CRM into Crystal Reports

    Hello All,
    Can anybody tell me how to get data into   crystal XI reports with MS CRM.
    Thanks in Advance
    Ramesh

    First you should refer to the Rules of Engagement and then add more info.
    Start off by telling us what version of CR are you using and what is MS CRM?
    Thank you
    Don

Maybe you are looking for

  • Cannot open iTunes 8 with Windows Vista Home Premium

    Hopefully someone here can help me with my problem. I have a new Ipod Touch that needs itunes 8 to work. I have a new HP PC with Windows Vista Home Premium. The problem I'm having is: itunes & quicktime will download successfully onto my computer, bu

  • A small problem in cfchart

    Hi, I am showing bar graph and line graph in the same chart. In the chart my line graph is behind the bar graph. I want the line graph shown above the bar graph. Thanks, Sriram

  • ITunes 11 setup question

    I've seen a lot of posts claiming that selecting "Show Side Bar" and "Show Status Bar" in the view menu will give the appearance of iTunes 10. I've found the view side bar, but where is view status bar? I don't see anything like that in any of the pu

  • Recording with Garage band 8

    I am new to Garage band (8)and I want to record texts. I have a MacBook with a built in microphone . I cannot start it . What is the procedure? C.Drache

  • Incompatible components

     I have HP Officejet All in ONe 8500 909a printer. I have Mac OS x 10.9 (Mavericks)  I get this error message on HP utility and when I go to support to find and dowload and update software to correct the problem, I cannot.  How do I find the newer co