How to append data..

I have an requirement where in transaction MIGO. when user clicks on POST button, at that time the data should be e-mailed to the Vendor.
So for that i have created a Z implementation of BADI MB_MIGO_BADI.
Now in that i have written a Function Module name as Z_SENDMAIL.
where i have table paramater which is of type BCSY_TEXT which is again of LINE type of SOLI.
Now the data of MIGO is filled in table IT_MSEG which is paramter of Method POST_DOCUMENT of MB_MIGO_BADI.
So problem comes that how should i fill the data in my line type table of Function Module.
For your information i am sending you the FM.
FUNCTION Z_SENDMAIL.
""Local Interface:
*" IMPORTING
*" VALUE(FROM) TYPE ADR6-SMTP_ADDR OPTIONAL
*" REFERENCE(TO) TYPE ADR6-SMTP_ADDR OPTIONAL
*" REFERENCE(SUBJECT) TYPE SO_OBJ_DES
*" REFERENCE(FLAG) TYPE CHAR1 OPTIONAL
*" EXPORTING
*" REFERENCE(RETURNCODE) TYPE SY-SUBRC
*" TABLES
*" IT_TEXT TYPE BCSY_TEXT
*" IT_EMAILS STRUCTURE SOMLRECI1 OPTIONAL
TYPES : BEGIN OF TS_REC,
RECIPIENT TYPE REF TO IF_RECIPIENT_BCS,
END OF TS_REC.
DATA : IS_T1(255) TYPE C,
IT_REC TYPE TABLE OF TS_REC,
IS_REC TYPE TS_REC,
W_EMAIL TYPE ADR6-SMTP_ADDR,
W_TEXT TYPE BCSY_TEXT,
W_DOCUMENT TYPE REF TO CL_DOCUMENT_BCS,
W_SENDER TYPE REF TO IF_SENDER_BCS,
W_RECIPIENT TYPE REF TO IF_RECIPIENT_BCS,
W_SENT_TO_ALL TYPE OS_BOOLEAN,
W_OREF TYPE REF TO CX_ROOT,
W_TEXT1 TYPE STRING,
W_SEND_REQUEST TYPE REF TO CL_BCS,
W_TABIX TYPE SY-TABIX.
CONSTANTS: C_TYPE TYPE SO_OBJ_TP VALUE 'RAW',
C_LENGTH TYPE SO_OBJ_LEN VALUE '12',
C_X TYPE C VALUE 'X'.
FROM = [email protected]'.
TRY.
create persistent send request
W_SEND_REQUEST = CL_BCS=>CREATE_PERSISTENT( ).
LOOP AT IT_TEXT INTO IS_T1.
APPEND IS_T1 TO W_TEXT.
CLEAR IS_T1.
ENDLOOP.
W_DOCUMENT = CL_DOCUMENT_BCS=>CREATE_DOCUMENT(
I_TYPE = C_TYPE
I_TEXT = W_TEXT
I_LENGTH = C_LENGTH
I_SUBJECT = SUBJECT ).
add document to send request
CALL METHOD W_SEND_REQUEST->SET_DOCUMENT( W_DOCUMENT ).
set sender
note: this is necessary only if you want to set the sender
different from actual user (SY-UNAME). Otherwise sender is
set automatically with actual user.
sender = cl_sapuser_bcs=>create( sy-uname ).
W_SENDER = CL_CAM_ADDRESS_BCS=>CREATE_INTERNET_ADDRESS( FROM
CALL METHOD W_SEND_REQUEST->SET_SENDER
EXPORTING
I_SENDER = W_SENDER.
add recipient (e-mail address)
create recipient - please replace e-mail address !!!
IF TO IS NOT INITIAL .
W_RECIPIENT = CL_CAM_ADDRESS_BCS=>CREATE_INTERNET_ADDRESS(
TO ).
CALL METHOD W_SEND_REQUEST->ADD_RECIPIENT
EXPORTING
I_RECIPIENT = W_RECIPIENT
i_copy = c_x
I_EXPRESS = C_X.
W_SEND_REQUEST->SET_SEND_IMMEDIATELY( 'X' ).
CALL METHOD W_SEND_REQUEST->SEND(
EXPORTING
I_WITH_ERROR_SCREEN = C_X
RECEIVING
RESULT = W_SENT_TO_ALL ).
COMMIT WORK.
ENDIF.
CATCH CX_SY_ARITHMETIC_ERROR INTO W_OREF.
RETURNCODE = 4.
W_TEXT1 = W_OREF->GET_TEXT( ).
CATCH CX_ROOT INTO W_OREF.
RETURNCODE = 4.
W_TEXT1 = W_OREF->GET_TEXT( ).
ENDTRY.
LOOP AT IT_EMAILS.
TRY.
CLEAR W_EMAIL.
W_EMAIL = IT_EMAILS-RECEIVER.
W_RECIPIENT = CL_CAM_ADDRESS_BCS=>CREATE_INTERNET_ADDRESS(
W_EMAIL ).
IS_REC-RECIPIENT = W_RECIPIENT.
APPEND IS_REC TO IT_REC.
CATCH CX_ADDRESS_BCS.
RETURNCODE = 4.
ENDTRY.
ENDLOOP.
LOOP AT IT_REC INTO IS_REC.
TRY.
W_SEND_REQUEST = CL_BCS=>CREATE_PERSISTENT( ).
W_DOCUMENT = CL_DOCUMENT_BCS=>CREATE_DOCUMENT(
I_TYPE = C_TYPE
I_TEXT = W_TEXT
I_LENGTH = C_LENGTH
I_SUBJECT = SUBJECT ).
add document to send request
CALL METHOD W_SEND_REQUEST->SET_DOCUMENT( W_DOCUMENT ).
set sender
note: this is necessary only if you want to set the sender
different from actual user (SY-UNAME). Otherwise sender is
set automatically with actual user.
sender = cl_sapuser_bcs=>create( sy-uname ).
W_SENDER = CL_CAM_ADDRESS_BCS=>CREATE_INTERNET_ADDRESS(
FROM ).
CALL METHOD W_SEND_REQUEST->SET_SENDER
EXPORTING
I_SENDER = W_SENDER.
CALL METHOD W_SEND_REQUEST->ADD_RECIPIENT
EXPORTING
I_RECIPIENT = IS_REC-RECIPIENT
I_EXPRESS = C_X.
W_SEND_REQUEST->SET_SEND_IMMEDIATELY( 'X' ).
CALL METHOD W_SEND_REQUEST->SEND(
EXPORTING
I_WITH_ERROR_SCREEN = C_X
RECEIVING
RESULT = W_SENT_TO_ALL ).
COMMIT WORK.
CATCH CX_SY_ARITHMETIC_ERROR INTO W_OREF.
RETURNCODE = 4.
W_TEXT1 = W_OREF->GET_TEXT( ).
CATCH CX_ROOT INTO W_OREF.
RETURNCODE = 4.
W_TEXT1 = W_OREF->GET_TEXT( ).
ENDTRY.
ENDLOOP.
IF FLAG = 'X'.
IF TO IS NOT INITIAL.
IT_EMAILS-RECEIVER = TO.
APPEND IT_EMAILS TO IT_EMAILS.
ENDIF.
ENDIF.
ENDFUNCTION.
So pls help me out asap its very Urgent.......
Regards,
DS

You can fill the data into the body or attach an attachment with the email.
For filling the data into the body, you can use the CONCATENATE statement.
LOOP AT IT_MSEG.
* concatenate all your fields here
  CONCATENATE IT_MSEG-MEBLNR IT_MSEG-MGJAHR INTO L_TEXT SEPARATED BY ' | '.
APPEND L_TEXT TO IT_TEXT.
ENDLOOP.
Pass this IT_TEXT to your table.
For creating an attachment you need to create a SMARTForm and than create a PDF attachment which can go alongwith the Mail.
Regards,
Naimesh Patel

Similar Messages

  • Datapump : How to append data in an existing table

    Hello Everyone,
    We are new to Datapump.
    We try to extract data from one user/schema and to append it into another user/schema.
    First we tried Tt use the parameter table_exists_action=append during the importation but we receive this error (but the rows are appended):
    ORA-39152: Table "XXXXX"."YYYYY_ZZZ" exists. Data will be appended to existing table but all dependent metadata will be skipped due to table_exists_action of append
    Which I don't expect since the utility have been told to, indeed, append data.
    Next we tried to use CONTENT=DATA_ONLY on exportation and importation but the importation never end.
    How can we append data into a table's user/schema without having an error?
    Best regards.
    Carl

    IGNORE=Y during the import.it does the same operation. if the table already exists,it ignores and proceed with importing/appending data to the tables. same way, they do have indexes=n and constraints=n option.
    both export/import have equivalent options for fitering to our requirement and datapump has one step above classic import in which you can filter upto metadata object as well.

  • How to append data in array

    I use three read waveform nodes to read data from three channels of
    oscilloscope. The data of each channel are 1D array, and I use build
    array node to change them into 2D array. It can work well now.
    When I want to continuously reading data, I put the read waveform nodes
    and build array node into a while loop structure(a timer controls the
    time when to stop). That means every time, the program calls read
    waveform nodes and then changes them into 2D array. The problem is:after
    each loop, the data stored in the 2D array are overwrited. So, at last,
    I can only get the last loop data.
    I want to append the data into the 2D array, but I do not know how to
    implement? I have tried put the build array outside the while loop,
    unfortunatel
    y, it does not work.
    Any advice would be appreciated.
    Sent via Deja.com http://www.deja.com/
    Before you buy.

    The shift register is a built in way to carry data forward from one
    iteration of a loop to the next iteration.. Anything that you feed into the
    right shift register appears a data at the beginning of the next loop. You
    already have Build Array to combine three 1D array Elements into a single 2D
    array. Use another Build Array function to combine the current 2D array
    with the previous 2D array to create a combined array. To do this, you must
    change the input mode of the Build Array function to Array (not Element).
    This will concatenate the arrays and make the continuous data that you are
    after.
    The only other hidden step is that you must use Initialize Array to feed a
    blank, 2D array into the left shift register to clear any leftover data.
    Michael Munroe Mailto:[email protected]
    A Better Complete Development Engineering Firm
    San Mateo, CA 94403 http://www.abcdefirm.com
    [email protected] wrote:
    > Because I am very new to Labview and in fact, English is not my native
    > language, I can not understand the sentence that "combine the current
    > reading with the previous reading from the left shift register and save
    > it back to the right shift register" means.
    >
    > Now, I want to descript my question in a simple way:
    > In a while loop, I use a build array node to build three 1D arrays into
    > one 2D array. For each time when while loop repeats, the value of these
    > 1D arrays change, I want to append the new data to the previous ones.
    > But in my program, the data in the build array are overrided after the
    > while loop repeating.
    > So, How to append the data instead of overriding them in the while loop
    > structure?
    >
    > Thanks a lot!
    >
    > zhljh
    >
    > In article <[email protected]>,
    > Michael Munroe wrote:
    > > You need to combine the build array function with the shift register.
    > Pop
    > > up on the edge of the loop and Add Shift Register. You can combine the
    > > current reading with the previous reading from the left shift register
    > and
    > > save it back to the right shift register.
    > > --
    > > Michael Munroe Mailto:[email protected]
    > > A Better Complete Development Engineering Firm
    > > San Mateo, CA 94403 http://www.abcdefirm.com
    > >
    > > [email protected] wrote:
    > >
    > > > I use three read waveform nodes to read data from three channels of
    > > > oscilloscope. The data of each channel are 1D array, and I use build
    > > > array node to change them into 2D array. It can work well now.
    > > > When I want to continuously reading data, I put the read waveform
    > nodes
    > > > and build array node into a while loop structure(a timer controls
    > the
    > > > time when to stop). That means every time, the program calls read
    > > > waveform nodes and then changes them into 2D array. The problem
    > is:after
    > > > each loop, the data stored in the 2D array are overwrited. So, at
    > last,
    > > > I can only get the last loop data.
    > > > I want to append the data into the 2D array, but I do not know how
    > to
    > > > implement? I have tried put the build array outside the while loop,
    > > > unfortunately, it does not work.
    > > > Any advice would be appreciated.
    > > >
    > > > Sent via Deja.com http://www.deja.com/
    > > > Before you buy.
    > >
    > >
    >
    > Sent via Deja.com http://www.deja.com/
    > Before you buy.
    Michael Munroe, ABCDEF
    Certified LabVIEW Developer, MCP
    Find and fix bad VI Properties with Property Inspector

  • How to append data in same log after start and stop signal express

    how can i append my data to the same log file after starting and stopping the signal express ? Is there some option to do this. After start/stop it always makes a new log file. How can append datat to the same log file. 
    Thanks in advance. 
    Munir

    Hello mbhatti,
    I founded a KB which seems do describe the way to solve your problem.
    Appending Data to the Same File when Logging in LabVIEW SignalExpress :
    http://digital.ni.com/public.nsf/allkb/C38AEE499D5CC8C6862572CF006875D2?OpenDocument
    I hiope this will help you
    Regards
    Florian Abry
    Application Engineer Group Leader
    NI Germany

  • How to append data  runtime in Table in MIDlet

    Hi Friends,
    i am having 2 queries..
    1st:: How can i append data runtime in table in MIDlet ( like web )which are coming from Database.
    2: requirement is that 1st row of table should for headings like StartDate,EndDate,Resources and Status.
    From the 2nd row ,Columns for runtime data.(Like any Table how u all got my query).
    Plz send me reply as early as possible.
    Waiting for reply
    Best regards
    karan

    Presently you cannot use AJAX kind of stuffs in J2ME.
    If you want to achieve the functionality better to look at articles wriiten on writing custom items in J2ME. That will help you achieve the kind of requirement that you are expecting.
    ~Mohan

  • How to append data from different import files?

    Dear experts,
    The customer is having different applications running that will output imports files BPC needs at a different time of process. Is it possible to append data which already exist in BPC from import?
    eg. BPC already has a record
    Factory1, Actual, 2008.OCT, Movement1, 30
    import file-
    Factory1, Actual, 2008.OCT, Movement1, 100
    and I need to add them up to become 130.
    Looks like regular import will only replace the original record by the new imported value. I'm still trying...
    Thanks a lot,
    Jim Hsu

    I do not think there is a way to use a standard import package to perform this action.  Typically when you are importing, you are saying this is the new value.  Not increment/decrement the value. 
    I have never had to implement a solution for a problem like this.  However, I would write a custom SSIS package that would extract the BPC data for the same dimensionality being imported and append it with the import file, then import the combined file.  Values sharing the same dimensionality in the same import file are aggregated on the actual import.
    SO your input file has 30, the export gets 100, the combined file has both and the actual value imported would be 130.
    That would be the approach I would take, but others might have more experience in different areas.

  • How to append data in column

    Hi ,
    I have One Column Name in Emp table Now name is varchar2(100) Now i n name column only first name exists now I wants to append surname in column without using update statement as column consist of first name i wants to append surname so please do advise how to append in column in oracle
    appriciate help.
    thanks

    You need something like this:
    UPDATE table_name
    SET ename=ename||' '||surname
    WHERE .....

  • How to append data in xml

    I have below script which will create xml with data.
    ======================================================================
    $xmlPath = "D:\Users\admin\Desktop\Report.xml"
    $date = Get-Date -UFormat %m/%d/%Y
    if ( ! ( Test-Path $xmlPath ) )
        # Create The XML
        $global:xmlWriter = New-Object System.XMl.XmlTextWriter($xmlPath,$Null)
        $global:xmlWriter.Formatting = "Indented"
        $global:xmlWriter.Indentation = "4"
        $global:xmlWriter.WriteStartDocument()
        $global:xmlWriter.WriteStartElement("Execution")
        $global:xmlWriter.WriteStartElement("ExecutedOn")
        $global:xmlWriter.WriteAttributeString("Date",$date)
        $global:xmlWriter.WriteStartElement("Environments")
        Foreach( $c in $cEnvironments)
            $global:xmlWriter.WriteStartElement($c.Environment)
            $global:xmlWriter.WriteAttributeString("Red",$c.Red)
            $global:xmlWriter.WriteAttributeString("Green",$c.Green)
            $global:xmlWriter.WriteAttributeString("Blue",$c.Blue)
            $global:xmlWriter.WriteEndElement() #end of $c.Environment
        $global:xmlWriter.WriteEndElement() #end Environments
        $global:xmlWriter.WriteStartElement("ClEnv")
        Foreach( $c1 in $clEnv)
            $global:xmlWriter.WriteStartElement($c1.Environment)
            $global:xmlWriter.WriteAttributeString("John",$c1.John)
            $global:xmlWriter.WriteAttributeString("Mike",$c1.Mike)
            $global:xmlWriter.WriteAttributeString("Alex",$c1.Alex)
            $global:xmlWriter.WriteEndElement() #end of $c1.Environment
        $global:xmlWriter.WriteEndElement() #end ExecutedOn
        $global:xmlWriter.WriteEndElement() #end execution
        $global:xmlWriter.WriteEndDocument() #end document
        $global:xmlWriter.Finalize
        $global:xmlWriter.Flush()
        $global:xmlWriter.Close()
    else
        here I need to append the data in existing xml with the same above info but with different value
    $cEnvironments $clEnv variables are array and having related data. Now I need to re run the script next day and check if the file is already exist. this is I am doing with if command. if it is already exist then using "else" I need to append the data
    in existing xml with the same above info but with different values under section "Execution" like given below
    ======================================================================
    <?xml version="1.0"?>
    <?xml-stylesheet type='text/xsl' href='style.xsl'?>
    <Execution>
        <ExecutionStarted Date="2/19/2014">
         <Environments1>
            <Colors Red="21" Blue="14" Green="18" />
        </Environments1>
        <Environments2>
            <Names John="21" Mike="14" Alex="18" />
        </Environments2>
    </ExecutionStarted>
    <ExecutionStarted Date="2/20/2014">
         <Environments1>
            <Colors Red="2" Blue="56" Green="76" />
            <Colors Cyan="31" Brown="32" Black="54" />
        </Environments1>
        <Environments2>
            <Names John="45" Mike="63" Alex="97" />
        </Environments2>
    </ExecutionStarted>
    </Execution>
    Thanks.

    I have below script which will create xml with data.
    ======================================================================
    $xmlPath = "D:\Users\admin\Desktop\Report.xml"
    $date = Get-Date -UFormat %m/%d/%Y
    if ( ! ( Test-Path $xmlPath ) )
        # Create The XML
        $global:xmlWriter = New-Object System.XMl.XmlTextWriter($xmlPath,$Null)
        $global:xmlWriter.Formatting = "Indented"
        $global:xmlWriter.Indentation = "4"
        $global:xmlWriter.WriteStartDocument()
        $global:xmlWriter.WriteStartElement("Execution")
        $global:xmlWriter.WriteStartElement("ExecutedOn")
        $global:xmlWriter.WriteAttributeString("Date",$date)
        $global:xmlWriter.WriteStartElement("Environments")
        Foreach( $c in $cEnvironments)
            $global:xmlWriter.WriteStartElement($c.Environment)
            $global:xmlWriter.WriteAttributeString("Red",$c.Red)
            $global:xmlWriter.WriteAttributeString("Green",$c.Green)
            $global:xmlWriter.WriteAttributeString("Blue",$c.Blue)
            $global:xmlWriter.WriteEndElement() #end of $c.Environment
        $global:xmlWriter.WriteEndElement() #end Environments
        $global:xmlWriter.WriteStartElement("ClEnv")
        Foreach( $c1 in $clEnv)
            $global:xmlWriter.WriteStartElement($c1.Environment)
            $global:xmlWriter.WriteAttributeString("John",$c1.John)
            $global:xmlWriter.WriteAttributeString("Mike",$c1.Mike)
            $global:xmlWriter.WriteAttributeString("Alex",$c1.Alex)
            $global:xmlWriter.WriteEndElement() #end of $c1.Environment
        $global:xmlWriter.WriteEndElement() #end ExecutedOn
        $global:xmlWriter.WriteEndElement() #end execution
        $global:xmlWriter.WriteEndDocument() #end document
        $global:xmlWriter.Finalize
        $global:xmlWriter.Flush()
        $global:xmlWriter.Close()
    else
        here I need to append the data in existing xml with the same above info but with different value
    $cEnvironments $clEnv variables are array and having related data. Now I need to re run the script next day and check if the file is already exist. this is I am doing with if command. if it is already exist then using "else" I need to append the data in existing
    xml with the same above info but with different values under section "Execution" like given below
    ======================================================================
    <?xml version="1.0"?>
    <?xml-stylesheet type='text/xsl' href='style.xsl'?>
    <Execution>
        <ExecutionStarted Date="2/19/2014">
         <Environments1>
            <Colors Red="21" Blue="14" Green="18" />
        </Environments1>
        <Environments2>
            <Names John="21" Mike="14" Alex="18" />
        </Environments2>
    </ExecutionStarted>
    <ExecutionStarted Date="2/20/2014">
         <Environments1>
            <Colors Red="2" Blue="56" Green="76" />
            <Colors Cyan="31" Brown="32" Black="54" />
        </Environments1>
        <Environments2>
            <Names John="45" Mike="63" Alex="97" />
        </Environments2>
    </ExecutionStarted>
    </Execution>
    Thanks.
    In my opinion, you are creating difficulties when you treat the problem as [xml] objects.
    A XML file is in fact, a TXT file, which can be interpreted in a specific way (XML way).
    But to this current problem, you can view the XML file as a common TXT file, with 1 important requirement: the closing main node ( </Execution> in your example ) must be in its own line, and must be the last line in the file.
    That said, you accomplish your task successfully, with this pretty much simple PS code:
    $xmlFile='.\XML.xml'
    $oldXmlText=@(gc $xmlFile)
    $newXmlText=$oldXmlText[0..($oldXmlText.Count-2)]+
    $inclusion+
    $oldXmlText[-1]
    Just compare this simplicity, with you original code's complexity.
    The XML.xml file content can be this:
    <?xml version="1.0"?>
    <?xml-stylesheet type='text/xsl' href='style.xsl'?>
    <Execution>
        <ExecutionStarted Date="1">
            <Environments1>
                <Colors Red="21" Yellow="14" Green="18" />
            </Environments1>
            <Environments2>
                <Names John="21" Mike="14" Alex="18" />
            </Environments2>
        </ExecutionStarted>
    </Execution>
    Notice the very last line.
    And the variable $inclusion can be this:
    $inclusion=@'
       <ExecutionStarted Date="2">
            <Environments3>
                <Names blue="21" black="14" cyan="18" />
            </Environments3>
       </ExecutionStarted>
    My Friend Come See How Abject Repugnant Politics... r.

  • How to append data from an internal table to an external table.

    HI everyone,
    I am trying to update an DB table type 'c'from the data captured in my internal table. can any one tell me as to how to do this.the contents of the DB table needs to be erased completly before i send in new data.
    Regards,
    Vj

    Assuming that you table has 1 character field(?) besides the MANDT field
    MANDT
    FIELD
    you need to update this db table with values from ITAB which I assume has one field of type c.
    To first delete all of the data from DB table.
    * Yes there are other ways of doing this.
    tables: ztable.
    select * from ztable.
    delete ztable.
    endselect.
    Then simply LOOP your internal table and update the table.
    loop at itab.
      ztable-field = itab-field.
      insert ztable.
    endloop.
    Regards,
    Rich Heilman

  • How to append datas to a text file?

    Hi,
    I want to append the data to a already created text file.When i used Write to text file.vi. It overwrites the previous data.
    Solved!
    Go to Solution.

    Try using the 'set file position' function (file io palette, advanced functions)  before you write the data.
    i.e. open the file, set position to end, write the data, close the file.
    Ian

  • How to append data from one file to another

    Hello,
    I am trying to replace one column of numbers in a 2D array with a unique string from another file.
    Pos.    Serial    Gain
     2        3252        4
     4        15697      4
     6        15543      4
    I want to replace the "4" in the third column with a string obtained from another file, such as;
    Serial # 3252 Fuel Cell # arxe-2282
    Time and date 09:47   09/08/07
    Version 4.0
    Serial # 1234 Fuel Cell # arxf-0047
    Time and date 09:50   09/08/07
    Version 4.0
    In this case, I want to replace the "4" in the first row of the top file (after the header) with "arxe-2282" from the file just above.
    This means I need to search though the second file (which will have multiple entries) and find the same serial number (in this case "3252") and then write the "arxe-2282" string in place of the "4" in the top file, right next to the "3252" number there.
    The search part is proving difficult. I can replace the "4" easy enough, but only if I already know where the "arxe-2282" is in the second file.
    Any ideas?
    Tay

    try this.....
    the program uses the match pattern and scan from string functions.  And there is still room for improvement.
    If you have to do is more often with bigger files, you should create a lookup table first. currently the files is scanned each time ....
    Greetings from Germany
    Henrik
    LV since v3.1
    “ground” is a convenient fantasy
    '˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'
    Attachments:
    find location.vi ‏11 KB

  • How to Append date time to the Source File Name in send Port without Orchestration

    Hi,
    I am using the Macro %SourceFileName%_%datetime%.zip in the filename(Send Port).
    say my file name is ABC.zip
    But I am getting the output as ABC.zip_2013T083444
    Please suggest, How to avoid the extension?
    Vignesh S ----------------------------------------------------------- Please use Mark as Answer if my post has solved your problem and use Vote As Helpful if my post was useful.

    The problem here is %SourceFileName% context property would return filename “With” extension. So when you use %SourceFileName%_%datetime%.zip you get FileNameWithExtension_Datetime
    For this you have to handle it either in customer pipeline component or in orceshtration where you have to remove the extension from the Filename.
    Read this post on remove the extension from this file name
    msgOut(FILE.ReceivedFileName) = System.IO.Path.GetFileNameWithoutExtension(msgIn(FILE.ReceivedFileName));
    After this if you use the
    %SourceFileName%_%datetime%.zip macro, you would get the desired output.
    If this answers your question please mark it accordingly. If this post is helpful, please vote as helpful.

  • How to append date in YYYYMMDD format in .par file for export

    Hi,
    Database Version: 10.2.0.4
    OS: AIX
    I have an export script which reads .par file and executes "exp" to export schema.
    I would like to add date in "YYYYMMDD" format for the dump file like this
    owner=scott file=/exports/scott_${`date '+%Y%m%d'`}.dmp feedback=10000
    I know above statement will not help, but I am giving it as example on what I want to achieve.
    I want the file name as =/exports/scott_20120712.dmp
    Thanks
    Sarayu

    user13312943 wrote:
    Hi,
    Database Version: 10.2.0.4
    OS: AIX
    I have an export script which reads .par file and executes "exp" to export schema.
    I would like to add date in "YYYYMMDD" format for the dump file like this
    owner=scott file=/exports/scott_${`date '+%Y%m%d'`}.dmp feedback=10000bcm@bcm-laptop:~$ export YYYYMMDD=`date '+%Y%m%d'`
    bcm@bcm-laptop:~$ echo $YYYYMMDD
    20120712
    bcm@bcm-laptop:~$
    owner=scott file=/exports/scott_${YYYYMMDD}.dmp feedback=10000

  • How to Append Date to Export Dump file name

    hi everyone,
    This is 10g on Windows.
    I want my dump file name to reflect the date it was ran on. I'm using the Job Scheduler tool in Database Control.
    So when I try EXPSSU%date.DMP as the dump file name, I get error "dump file name "EXPSSU%d.DMP" contains an invalid substitution variable ."
    what is the correct syntax? I dont care about the formatting of the date - whatever the default is will be OK.
    Thanks, John

    i have the same problem, any one have the solution?!?!??!

  • Appending data from one table to another

    Hello
    How to append data from one table t1 to another table t2.
    t1 and t2 have the same structures .
    t2 contains already data so i don't want do delete it and create it as select * from t1.
    If there is a mean to add t1 content without altering t2 content.
    Thanks in advance

    insert into t2
      select * from t1

Maybe you are looking for