Letters to be auto generated via Word templates

Hi Experts,
We are trying to auotmate the letter generation through dynamic actions in PA30. e.g. We want to generate the appointment letter in word document after completion of the hiring action. We have customised a new infotype and the sub type under the same. We have uploaded the word template in OAER also. But we are not able to generate the letter after completion of the action. Can someone let us know where we are going wrong. It would be of great help if someone can give the list of the steps to be followed.
Appreciate your prompt response.
Regards,
Sateesh

Hi Experts,
Custom development is done even the driver program is done which will execute the word template but there is a issue when i do the
action in PA30 it give an error no letter stored can u please guide me with the step which need to be followed.
Regards,
Sateesh.

Similar Messages

  • EWA - Auto Generate Word Report

    Dear all,
    When the EWA report create each week, we need click the "word" icon to generate word report.
    Is it possible to auto generate EWA word report ?
    Best Regards,
    Wu

    Hello,
    It seems like your system is already setup to generate the report automaticallly. Usually when you have the 'Word' icon, it means the report has been generated correctly. By clicking on that icon, you are just opening the report.
    If you want to have the report  or solution to automatically forward to your email address, please navigate to the link below for the PDF activation file. This will provide youwith the steps required to setup the automatic emailing of the report.
    http://service.sap.com/~sapidb/011000358700001873212008E
    Regards,
    Jared

  • Auto-generating word documents from word templates

    How would one go about generating a word document based off of a word template (.dot)? For example, I have a simple JSP form which has a field "Last Name". When submitted, the "Last Name" is plugged into a corresponding bookmark in a .dot file. Then the .dot file is saved as a .doc file and presented to the user for download. So, breaking it down:
    1. User fills out a jsp form with "Last Name" and hits the submit button
    2. The submit button triggers a routine to:
    a. open a .dot file on the server (static location)
    b. find the bookmark where the last name should be plugged in
    c. plugs the value of last name
    d. saves the .dot as a word document
    e. presents to the user for download
    Has anyone done a similar thing before? Any pointers?

    There's a lot of templating projects around that are usable in Java. I'm not aware of any that use closed proprietary technology like Word and I wouldn't base my design on that either. If you're stuck with that idea then I don't have any suggestions.

  • My client asks ... can we generate a PDF not via Word...?

    Using: RH HTML 7.0.3.
    Hi all,
    A client has invested time into developing a good CSS style sheet and RoboHelp template for creating a nice looking CHM HTML Help. My client wants to find a way of creating a nice looking PDF document without investing more time in developing a good Word template for export to PDF.
    The client asked me what seems to me to be a dumb question about PDF generation. Is there such a thing as generating a PDF not via Word? - (Whatever that means.) My client seems to think there is a way. But since my client asked, I have to ask you all...
    I tried out the quick way of simply clicking on the PDF icon, and seeing what happens. So RH generated for me a PDF, without asking me for any more info. The Output logger showed clearly that RH was first creating a *Word file*. And sure enough when I looked in its target folder I saw there was also a *Word doc* there, completed a minute earlier. A definite sign, I think, that RH first created the Word doc and then from it created the PDF. (Btw, I don't know where RH got the TOC from for this PDF generation - it seems like a ghost of the TOC I used months ago.) 
    Then I tried using the Generate wizard from the Single Source Layouts pod. One of the stages of this wizard prompts you to select a template, including any *Word templates* you have fed RH in the past. Again a good sign, IMO, that the initial process for making a PDF is the same as for making a Word doc.
    Over to you all.
    TIA
    avraham

    RH has to create a Word document but if you deselect the Word check box, it is not saved. What you saw was probably an old document. Delete it and publish just a PDF and you should not be able to see the temporary Word document that is created.
    In the wizard you don't have to select a Word template, that is just one of the options.
    The content of the print layout is not related to your TOC. It takes the content of a TOC when you first create the print layout but then the two are standalone. You might not want the print layout to be the same as the TOC. If you do, use the arrows to clear the content and then replace it with the current TOC.
    This is covered in Printed Documents on my site.
    See www.grainge.org for RoboHelp and Authoring tips
    @petergrainge

  • Help for -Generate Report using Word template having company Logo

    HI GUys,
    I am trying to generate a report in PDF using the word template having some company logo as footer to that .
    When user click on print ,the graph should be added to the template and its should output the report in pdf.
    I am able to achive this when I 'm  not using the template,but when I use the template (sample code shown below),its throws the error attached in screenshot.
    pls suggest the possible way to achieve this

    Why are you deleting the file after creating the report? Are you sure that the image exists at the path specified when running?
    Also, in your top screenshot because of data flow there's a high possibility that you actually delete the file before it gets used because there is no connection between the end of writing the report and deleting the picture.
    I also suspect there's a chance there might be a permissions issue - you are trying to get the file from another user's desktop which isn't normally allowed - do the file/folder permissions give you access to that file path? I would try putting the picture on your own desktop just to rule that out.
    Certified LabVIEW Architect, Certified TestStand Developer
    NI Days (and A&DF): 2010, 2011, 2013, 2014
    NI Week: 2012, 2014
    Knowledgeable in all things Giant Tetris and WebSockets

  • How to generate PDF from template via REST query

    Hello. I'm newbie in Adobe LiveCycle, will appreciate any help.
    What we need: generate PDF from template, using different data.
    What we have: LiveCycle Designer and server with deployed Adobe LiveCycle ES 2.5 image.
    Looks like server works and listen 8080.
    In Livecycle Designer I can generate XML (XDP) from PDF, so I can change this XML in PHP/Python/Go script to fill template with data.
    I'm looking for some REST method, where I can give that XML (XDP) and recieve generated PDF in response.
    I've spent whole to for googling all these things, found a lot of docs, but all is very complicated there. Also, examples from just doesn't work - maybe I have to do something on server before calling REST API method.
    Please, push me into right direction

    Your best bet is to probably create an orchestration (or "process" in Adobe speak) that accepts two document parameters, calls LiveCycle Forms (or Output depending on whether you want to interactive or non-interactive PDF), and returns the resulting document variable.
    The orchestration will return a redirect that will point you to the document object.
    See Invoking LiveCycle using REST Requests, and Creating Your First LiveCycle ES4 Application.
    Rob

  • Links generated by Word Adobe plug-in are too large

    Surprise me...by helping me to come up with a solution to this obscure, but very annoying, issue.
    Our company recently moved from Office 2003 to 2010 and from Acrobat Pro 9 to X.  We are still using Windows XP.  Our standard process involves generating PDFs with internal links via an Adobe plug-in to Word--elements such as cross references and TOCs generated in Word are turned into PDF links via Distiller (not a server install).
    The problem is that the links that are created using all this upgraded software are "larger" than they used to be.  They encompass more than just the letters of the cross reference and often include punctuation that follows, such as periods and closing parens.  This means that when we continue with our process of turning linked text blue, characters turn blue that should be black.  The old setup did not do this.
    Is there any way to adjust the margins/buffer/link size so that the links that are created are tighter around the linked text?  Is there another way to address this?  Adjusting each link of a large document is unsustainable, but leaving these characters blue is unacceptable.
    Your help is appreciated!

    Thanks very much for your reply.
    I was hoping there would be some tweak I could make to the settings of Distiller or maybe some registry tweaks to change the link rectangle buffer size prior to the creation of the PDF links from the Word document.  I understand that the links are just "rectangles on the page" once they exist in the PDF document--but even a script to decrease the size of all of the links in all directions after rendering the PDF would be helpful, since the increase in size seems to be in all directions.
    I suppose I can export the links to a spreadsheet and create a formula to decrease the link measurements by a specified amount and then re-import them.
    I wonder what caused the change.
    Here is a screenshot of the difference if it helps at all.  It's at two different magnifications, but you can still see that the period is included in one and not in the other.  And the link box is larger in all directions.
    Thanks again.

  • Auto generated types and ps1xml formatting files

    Hello,
    I'm using New-WebServiceProxy to work with a web service... when I call methods of the web service powershell auto generates types, for example, things like "Microsoft.PowerShell.Commands.NewWebserviceProxy.AutogeneratedTypes.WebServiceProxy1_webservices_awebservicepage_asmx.TheMethodReturnObjectType"
    1. should I just use that type name in my ps1xml formatting file? I'm wondering if that will be fragile... seems fragile like 'webServiceProxy1' for example, what if there is some scenario it uses '2'? Not sure if I can count on that being consistent?
    2. I started creating custom objects and adding my own type name to them so that type name could be used in the ps1xml file. This works fine. However so far it was for web service methods that returned single instance results.. now I hit a point where I'm
    calling a web service method that will return a collection... so I'm wondering if it would be better to just use the auto generated type name  in the ps1xml or, as I would need to do in this case, actually enter a foreach loop to create a new custom object
    for every object in the returned collection? In other words, for the web service methods I've used so far for this, I simply created my custom object and write-output... for the case of the collection, I would be new-object'ing and write-output'ing within
    that foreach loop.. wondering about performance issues, or if it's just overkill when I could just put that auto generated type name in the ps1xml file and be done with it... 
    not sure if I've asked that very clearly...
    essentially, I'm wondering if it's overkill (from a resource usage perspective) to be creating these custom objects in the case of when there will be a collection, with potentially hundreds of items, when the only reason I'm doing it is for display purposes...
    if it were not an autogenerated type I would simply use the type name in the ps1xml, I'm just not sure if I can do that in this case as I don't know if that typename will *always* be the same?
    any input would be appreciated, thanks

    Hi DJC,
    I haven't rexperienced this, however, to create a .ps1xml file, these examples may be helpful for you:
    Creating a module for powershell with a format file
    discutils / utils / DiscUtils.PowerShell / DiscUtils.Format.ps1xml
    about_Format.ps1xml
    I hope this helps.

  • Saving only a portion of a Microsoft Word template into a new document using LabVIEW Report Generation Toolkit

    I have a Microsoft Word template I want to populate programmatically with test data. The template contains both explanatory text and a data sheet section with test data placeholders (bookmarks). Using the Report Generation Toolkit for Microsoft Office, I have been able to successfully populate the placeholders with data and save the results into a new Microsoft Word document. The problem is the new Word document contains not only the test data but also the explanatory text that was in the original document template. Ideally, I would like to have the generated document contain just the test data without the accompanying text. Is it possible to do this usi
    ng the Report Generation Toolkit?

    Hello Ryan,
    Two easy options come to mind.
    1. You may want to consider using an �ink annotation� instead of regular text for your explanation.
    2. You can programmatically do a find and replace on the explanatory text. Have LabVIEW find the whole paragraph, and replace it with nothing.
    If none of these suggestions help, or if I�m not correctly understanding your issue, please reply with comments or answers to the discussion above and any additional information that may help, and I�ll be happy to look further into it.
    Have a nice day!
    Robert Mortensen
    Applications Engineer
    National Instruments
    Robert Mortensen
    Software Engineer
    National Instruments

  • Report Generation - Word Template

    Hi,
    I am trying to write a program that captures up to 873 different scope shots.
    At the end, the program will generate a Word Report with all scope shots and measured parameters.
    I have used the Word Template in the past and created field for each parameters.  However, this approach will not be efficient with this complex test.  The report format of each test is shown below with the read box indicating the field where data will be plugged in by LabVIEW.
    To create the word template for entire tests can create unnecessary post processing to delete the part of the test that user didn't run.  If user ran only 3 tests then he would have to delete other 870 templates which will not be cost efficient.  Also, this could create unnecessary programming mess that is not very flexible.
    My questions -- is there any way I can copy this template below as I run the test?  Rather than creating a word template for 873 different test for which I may only run part of it, can I copy the template based on number of test that user would like to run?
    Any pointers will be appreciated.
    Thanks,
    Chetna
    Intersil Inc.
     919-405-3696
     Example of the scope data figure:
    Figure Error! No text of specified style in document.‑1. □
    1. □
    2. □
    3. □
    4.  □
    Test Conditions:Vin=□V,  Vout=□V: □A Temp=□C Mode=□Fs=□Serial #=□ 

    Hi Vivek,
    I have LabVIEW 8.5 Development version and the report generation tool kit.  I will be writing VI to fill the data in and generate a word report with Up to 873 different tests.  The template that I attached is the sample template for only one test, I will be doing 873 tests.  The sample test template consists of scope shot and some measured parameters.
    My situation - the VI that I will be writing will fill in the sample template that I attached for 873 times.  For me to generate a word report for all tests, I would have to create a report template with 873 sample templates.  Where there is a red box, I would have to create a field for each box so the LabVIEW will know where to put the data in. 
    Well, that is lot of work in the first place.  Secondly, to keep up with 873 different permuation fields can create lot of unnecessary programming mess.  Lastly, if the user decide to run only part of the test, then there would be lot of empty test templates.  If user decide to run only 10 tests the final report will have 860 empty boxes.  That is not efficient.
    My goal is to create the word report using just one sample template rather than 873.  I would like to copy the sample template based on number of tests user defines. 
    My question is-  Is there any way to copy the sample test template that I attached using the report generation toolkit?
    Regards,
    Chetna Tailor

  • XML Publisher/Bi Publisher Using Oracle Package and MS Word Template builde

    My Question is I want to know more about grouping of elements while creating reports in E business suite.
    my approach should be 1. pl sql package with embedded XML data to create xml output. 2. Formatting the xml output using ms word template builder plugin.
    My question is if grouping is required, then where should it be? While creating package to generate xml output or while formatting xml o/p in ms word?
    I wanted to create a check cancellation report where the report should look like below.
    Bank Name American express
    Bank address 1 Cape town city Road
    bank address 2 Lane 2
    Bank City Cape town
    Branch Docara v'dola
    Check number Amount Vendor Status
    1023423 225 huawei Voided
    1023430 500 Ericson Voided
    Signature
    Now for above grouping I Written some thing like below package:
    But I want to know Had I not done the grouping in Package, would it have still be possible to do the grouping in MS Word template builder?
    To simply fy question: If I had not written 2 cursors and written 1 simple cursor and had got simple 1 after 1 fields without any specific grouping in ora package, would it have been possible to do the same grouping while formatting the xml output in MS word template builder?
    the part of code enclosed.
    begin
    DBMS_APPLICATION_INFO.SET_CLIENT_INFO(FND_PROFILE.VALUE('ORG_ID'));
    --fnd_file.put_line (fnd_file.output, '<?xml version = "1.0" encoding="ISO-8859-1"?>');
    fnd_file.put_line(fnd_file.output, '<G_HEAD>');
    for rec1 in c_bank_main
    loop
    fnd_file.put_line(fnd_file.output, '<G_BANK>');
    fnd_file.put_line (fnd_file.output,'<c_bank><![CDATA['|| rec1.c_bank ||']]></c_bank>');
    fnd_file.put_line (fnd_file.output,'<c_bank_acc><![CDATA['|| rec1.c_bank_acc ||']]></c_bank_acc>');
    fnd_file.put_line (fnd_file.output,'<c_bankadress1><![CDATA['|| rec1.c_bankadress1 ||']]></c_bankadress1>');
    fnd_file.put_line (fnd_file.output,'<c_bankadress2><![CDATA['|| rec1.c_bankadress2 ||']]></c_bankadress2>');
    fnd_file.put_line (fnd_file.output,'<c_bankadress3><![CDATA['|| rec1.c_bankadress3 ||']]></c_bankadress3>');
    fnd_file.put_line (fnd_file.output,'<c_bankcity><![CDATA['|| rec1.c_bankcity ||']]></c_bankcity>');
    fnd_file.put_line (fnd_file.output,'<c_branch><![CDATA['|| rec1.c_branch ||']]></c_branch>');
    for rec in c_bank_child(rec1.c_bank)
    loop
    fnd_file.put_line(fnd_file.output, '<G_CHECK>');
    fnd_file.put_line (fnd_file.output,'<c_currency_code><![CDATA['|| rec.c_currency_code ||']]></c_currency_code>');
    fnd_file.put_line (fnd_file.output,'<c_pay_currency_code><![CDATA['|| rec.c_pay_currency_code ||']]></c_pay_currency_code>');
    fnd_file.put_line (fnd_file.output,'<c_cleared_amount><![CDATA['|| rec.c_cleared_amount ||']]></c_cleared_amount>');
    fnd_file.put_line (fnd_file.output,'<c_nls_status><![CDATA['|| rec.c_nls_status ||']]></c_nls_status>');
    fnd_file.put_line (fnd_file.output,'<c_nls_status><![CDATA['|| rec.c_nls_status||']]></c_nls_status>');
    fnd_file.put_line (fnd_file.output,'<c_check_stock_name><![CDATA['|| rec.c_check_stock_name ||']]></c_check_stock_name>');
    fnd_file.put_line (fnd_file.output,'<status_lookup_code><![CDATA['|| rec.status_lookup_code ||']]></status_lookup_code>');
    fnd_file.put_line (fnd_file.output,'<c_check_number><![CDATA['|| rec.c_check_number ||']]></c_check_number>');
    fnd_file.put_line (fnd_file.output,'<c_sum_amount><![CDATA['|| rec.c_sum_amount ||']]></c_sum_amount>');
    fnd_file.put_line (fnd_file.output,'<c_vendor_name><![CDATA['|| rec.c_vendor_name ||']]></c_vendor_name>');
    fnd_file.put_line (fnd_file.output,'<c_doc_sequence_value><![CDATA['|| rec.c_doc_sequence_value ||']]></c_doc_sequence_value>');
    fnd_file.put_line(fnd_file.output, '</G_CHECK>');
    end loop;
    fnd_file.put_line(fnd_file.output, '</G_BANK>');
    end loop;
    fnd_file.put_line(fnd_file.output, '</G_HEAD>');
    end

    Hi,
    You can do grouping in either place. But ideally to avoid re-grouping in the BI Publisher Template your XML would be generated such that it is appropriate for your template.
    This is really important when it comes to very large datasets as you should avoid regrouping in the template in this case.
    Regards,
    Gareth
    http://garethroberts.blogspot.com
    http://www.virtuate.com

  • HOW TO GET AUTO GENERATED PRIMARY ID KEY BACK FROM AN INSERT STATEMENT IN .

    Just recently I ran into a problem with what seems to be a deficiency in the Oracle Database. When trying to return an auto-generated key as is done in Microsoft's SQL database, it seems Oracle for whatever reason didn't add this capability, the key couldn't be passed back to the .Net call. After tinkering with the .Net software and talking with the Oracle techs, a decent work around to the problem (presented here) comes fairly close. Two things have to be done first before this will work. A sequence has to be created on the Oracle DB. Also a trigger has to be created against the table the keys are going to be returned from.
    The class works by passing to the function 'update_datasets_return' a DataSet with as many tables as you want. The function spins through the tables and put the keys in each row inserted. It's assumed the first row will either be the primary key or some numeric value. This can be changed by modifying the: dt.Columns(0).ColumnName
    Notice the word Inserted. On Updates and Deletes the key value is ignored because it's already present. The routine just updates the database as usual.
    So in other words you could send a table to the function with rows inserted, deleted, or updated and it will take care of them all. One routine for all.
    ' ======================================================================
    ' Created by SEF and Oracle SR: 5607364.993 This is a complete Redo
    ' of the initial concept. SEF...
    ' Sample of sequence and trigger at bottom.
    ' Uses the ODP.NET data provider.
    ' update_datasets_return: Goes thru each table in the dataset and
    ' updates, deletes, or inserts as needed.
    ' If inserting, a 'sequence counter' and a 'trigger'
    ' using the 'before insert' must be present. The sequence
    ' counter is set to auto increment by 1 starting at 1.
    ' The trigger is specific to the table.
    ' Create the trigger and sequence in the database or run the samples
    ' below in PL/SQL. Be sure the logon with a user that has enough rights.
    ' Routine assumes the first column is going to hold the sequence
    ' number. Actually any column could be used. Just change the
    ' dt.Columns(0).ColumnName to whatever you want or leave as default.
    ' The da_RowUpdated sub is where the 'sequence number' gets returned
    ' on each row that is inserted into a table. Routine is ignored on
    ' deletes and updates. SEF...
    ' =======================================================================
    Imports System
    Imports System.Data
    Imports Oracle.DataAccess.Client
    Imports Oracle.DataAccess.Types
    Public Class OracleUpdate
    Private Shared m_conn As OracleConnection
    Private Shared da As New OracleDataAdapter
    Private Shared dt As DataTable
    Private Shared conn As New OracleConnection
    Private Shared dr As DataRow
    Private Shared astep As Long
    Private Shared rwIndex As Integer = 0
    Private Shared tblIndex As Integer = 0
    Public Shared Function update_datasets_return(ByVal constr As String, ByVal ds As DataSet) As DataSet ''ByRef ds As DataSet)
    Dim selectstmt As String
    m_conn = New OracleConnection(constr)
    Try
    m_conn.Open()
    Catch ex As Exception
    Throw New ArgumentException(" Error: connection lost." & ex.Message)
    End Try
    For Each dt In ds.Tables
    ''Uncomment the code only if auto numbering
    ''is NOT turned on for the table being updated. SEF...
    ''rwIndex = 0
    ''For Each dr In dt.Rows
    '' Try
    '' Select Case dr.RowState
    '' Case DataRowState.Added
    '' astep += 1
    '' ' =======================================================
    '' ' This "Try Catch" section created only if auto numbering
    '' ' is NOT turned on for the table being updated. SEF...
    '' ' It's a crude attempt at creating a unique number.
    '' ' A more serious approach would be to use a GUID.
    '' ' Use only if you decide not to have a sequence and a
    '' ' trigger for the table.
    '' ' =======================================================
    '' Try
    '' 'ds.Tables(tblIndex).Rows(rwIndex).Item(0) = astep
    '' Catch
    '' ' ignore the error corrected integer identity so don't randomize it
    '' End Try
    '' dr.Item("createdDate") = Now
    '' dr.Item("changedDate") = Now
    '' Case DataRowState.Modified
    '' dr.Item("changedDate") = Now
    '' End Select
    '' Catch ex As Exception
    '' conn.Close()
    '' conn.Dispose()
    '' Throw New ArgumentException(" Error: update_datasets " & ex.Message)
    '' End Try
    '' rwIndex += 1
    ''Next
    selectstmt = "SELECT * From " & dt.TableName & " Where " & dt.Columns(0).ColumnName & " = " & 0
    da = New OracleDataAdapter(selectstmt, m_conn)
    Dim bldr As OracleCommandBuilder = New OracleCommandBuilder(da)
    AddHandler da.RowUpdated, New Oracle.DataAccess.Client.OracleRowUpdatedEventHandler(AddressOf da_RowUpdated)
    Dim insCmd As OracleCommand = Nothing
    Try
    insCmd = CType(bldr.GetInsertCommand(), OracleCommand)
    Catch ex As Exception
    Throw New Exception("")
    End Try
    insCmd.CommandText += " returning " + dt.Columns(0).ColumnName + " into :seqno"
    insCmd.Parameters.Add(New OracleParameter("seqno", OracleDbType.Int16, _
    4, ParameterDirection.Output, False, CType(0, System.Byte), CType(0, _
    System.Byte), dt.Columns(0).ColumnName, DataRowVersion.Current, Nothing))
    da.InsertCommand = insCmd
    Try
    ' ===========================
    da.Update(ds, dt.TableName)
    ' ===========================
    Catch ex As Exception
    Throw New ArgumentException(" Error: update_datasets_return " & ex.Message)
    End Try
    Next
    m_conn.Close()
    m_conn.Dispose()
    Return ds
    End Function
    Friend Shared Sub da_RowUpdated(ByVal sender As Object, ByVal e As OracleRowUpdatedEventArgs)
    If e.StatementType = StatementType.Insert Then
    e.Row(0) = Int64.Parse(e.Command.Parameters("seqno").Value.ToString())
    End If
    End Sub
    ' ================================================================================
    ' Notes:
    ' =================== How To -- Sample section for PL/SQL ==================================
    ' myTrigger, myTable, mySequence, and myColumn are values you need to supply.
    ' Note: A trigger needs to be created for each table.
    ' A sequence needs to be created only once and referenced each time
    ' in the trigger(s). Or you could create a new sequence each time you
    ' create a trigger. Sort of a waste of effort.
    ' Explanation:
    ' myTrigger = The name you are giving this trigger.
    ' If a trigger with same name already
    ' exist, it will be overwritten.
    ' myTable = Table you want to add the sequence numbers to.
    ' mySequence = Sequence counter you created. Whatever name you called it.
    ' myColumn = The column to update with the sequence number.
    ' =================================================================================
    ' -- Run in PL/SQL or create at DB. --
    ' create or replace trigger myTrigger
    ' before insert on myTable for each row
    ' begin
    ' select mySequence.nextval into :new.myColumn from dual ;
    ' end;
    ' -- Run in PL/SQL or create at DB. --
    ' create sequence mySequence
    ' MINVALUE 1
    ' START WITH 1
    ' INCREMENT BY 1
    ' NOCACHE; can be set to CACHE but sequence may contain gaps.
    ' Explanation of CACHE from: http://www.techonthenet.com/oracle/sequences.php
    ' With respect to a sequence, the CACHE option specifies how many sequence
    ' values will be stored in memory for faster access. The downside of creating
    ' a sequence with a CACHE is that if a system failure occurs, all cached
    ' sequence values that have not be used, will be "lost". This results in
    ' a "gap" in the assigned sequence values. When the system comes back up,
    ' Oracle will CACHE new numbers from where it left off in the sequence,
    ' ignoring the so called "lost" sequence values.
    ' Note: To recover the lost sequence values, you can always execute an
    ' ALTER SEQUENCE command to reset the counter to the correct value.
    ' NOCACHE means that none of the sequence values are stored in memory.
    ' This option may sacrifice some performance, however, you should not encounter
    ' a gap in the assigned sequence values.
    End Class
    C#:
    using System;
    using System.Data;
    using Oracle.DataAccess.Client;
    using Oracle.DataAccess.Types;
    public class OracleUpdater2
    private static OracleConnection m_conn;
    private static OracleDataAdapter da = new OracleDataAdapter();
    private static OracleConnection conn = new OracleConnection();
    public static DataTable load_it(string constr, string strqry, string tblName)
    // =====================================================================
    // constr = User Id=myUser;Password=myPass";Data Source=myDataSource
    // strqry = Select * from something?
    // tblName = The table name to fill.
    // =====================================================================
    conn = new OracleConnection(constr);
    conn.Open();
    da = new OracleDataAdapter(strqry, conn);
    OracleCommandBuilder bldr = new OracleCommandBuilder(da);
    DataTable dt = new DataTable(tblName);
    da.Fill(dt);
    conn.Dispose();
    return dt;
    public static DataSet update_datasets_return(string constr, DataSet ds)
    //'ByRef ds As DataSet)
    string selectstmt = null;
    m_conn = new OracleConnection(constr);
    try
    m_conn.Open();
    catch (Exception ex)
    throw new ArgumentException(" Error: connection lost." + ex.Message);
    foreach (DataTable dt in ds.Tables)
    selectstmt = "SELECT * From " + dt.TableName + " Where " +
    dt.Columns[0].ColumnName + " = " + 0;
    da = new OracleDataAdapter(selectstmt, m_conn);
    OracleCommandBuilder bldr = new OracleCommandBuilder(da);
    da.RowUpdated += new
    Oracle.DataAccess.Client.OracleRowUpdatedEventHandler(da_RowUpdated);
    OracleCommand insCmd = null;
    try
    insCmd = (OracleCommand)(bldr.GetInsertCommand());
    catch (Exception ex)
    throw new Exception("" + ex.Message);
    insCmd.CommandText += " returning " + dt.Columns[0].ColumnName + " into
    :seqno";
    insCmd.Parameters.Add(new OracleParameter("seqno", OracleDbType.Int16, 4,
    ParameterDirection.Output, false, System.Convert.ToByte(0),
    System.Convert.ToByte(0), dt.Columns[0].ColumnName, DataRowVersion.Current,
    null));
    da.InsertCommand = insCmd;
    try
    // ===========================
    da.Update(ds, dt.TableName);
    // ===========================
    catch (Exception ex)
    throw new ArgumentException(" Error: update_datasets_return " +
    ex.Message);
    m_conn.Close();
    m_conn.Dispose();
    return ds;
    If you need a working program of how this works, let me know.

    Oh my god, it is too long! You definitely check out types, casting and especially ODP.Net (it does everything for you)... etc. They can help you to simplify your code. I do not have enough time to copy paste it to Studio and understand and solve your issue, so I got title of your message as your main question.
    In Oracle, you can create an autonumber field by using sequences object. This is really useful when you need to create a unique number to act as a primary key.
    Basically you can create a sequence simply typing;
    CREATE SEQUENCE MY_SEQUENCE;
    now you have a sequence called "MY_SEQUENCE"... Then, I advice you select a number from sequence;
    select MY_SEQUENCE.nextval from dual;
    I said I advice actually kinda must, although it called sequence, I cannot be sequential. Do not even try to predict the value. You can be sure that it is unique number so you can use it.
    Then insert you record and use that number part of your primary key. I think that's it. Have fun.

  • How to set the AS2 fileName for outbound Functional Ack 997 auto generated by Oracle B2B

    Hi Friends,
    How to set the AS2 fileName for outbound Functional Ack 997 auto generated by Oracle B2B.
    External Trading Partner is sending the EDI 856 via AS2 URL to our Oracle B2B Server.
    In the inbound 856 agreement, we have checked the option of Funtional Ack and also Functiona Ack handled by B2B is yes.
    We have the outbound agreement which is sending that Functional ack 997 (auto generated by oracle b2b) and we have specified the Outbound AS2 channel of the Partner.
    997 doc is being sent to external partner using AS2 channel, but the filename is generating as '40101'.
    Please can you let me know how to set the AS2 fileName for outbound Functional Ack 997 auto generated by Oracle B2B.
    Appreciate your valuable answers!!
    Thanks,
    Amirineni

    Amirineni,
    AFAIK, there is no option to set the file name when the 997 is generated automatically by B2B.
    Alternatively, if this is a must requirement, you can generate the FA from backend and  send to B2B with MSG_TYPE =9. In this case, you can set the header with filename (How to set the actionname property in B2B 11g)

  • Help Required :Unable to auto generate the layout in BIP

    Hi All,
    This is Ronny, I am really having a tough time using OBIEEE. I am trying to create a simple report in which when i try to auto genreate a rtf template then it says *" failed to load the layout"* and gives me connection timed out error ( unable to autoload). I edited it and tried a simple select statement but still no luck.
    Has somebody else faced the same problem, I request you to please give me your inputs on the same.
    Thanks in advance
    Ronny.

    Hi Sree,
    Thanks a alot for replying, i use the query builder to build the initial query but even after that it fails to auto load the template. I tried building the simplest of queries through the query builder but got the same error even when the query runs fine in TOAD . However, upon trying again i got some luck and it generated the template. But still for me, its a hook and crook means i am not sure that that it would generate the template again for me or not.
    Thanks alot for replying ..however, i am working on this and will get back to you once i get the error again.
    Thanks
    Ronny

  • MS Word Template in Content Server

    Hi, we have this problem.
    we have a Z transactions asking the user to give some data and save it in a table with key number, the user can attach several documents (.DOC) from local pc and transaction use content server to store these documents and linked it to the data stored in table via the key document. all of this is working fine. we are using  ARCHIVOBJECT_CREATE_FILE and ARCHIV_CONNECTION_INSERT functions to save this file in content server and link the document to the key number.
    now we are trying to make the transaction open a  MS  word template , the user fill the word document and when its done the transaction save it in content server
    some can give some help to do this?
    we are searching a way to :
    1.- store a Ms Word template in SAP
    2.- Open this MS Word template with a button in the  Z transaction.
    3.- Let the user fill the template .
    3.- save the document filled in content server without change the original template and linked to the data with the same key number.
    thanks.

    All catch is to insert table in the correct level of xml schema.
    1. So you first need to insert add elements to the template until you reach the element that you want to use in the table. For example if you want to display items of orders, this level would be Transactionhistoryofheader - Btdocflowall - Item
    2. After that you would insert table with 2 rows and as many columns as you need.
    3. The first row of the table is used for column headers. You can type in freely any text you want to display in column headers.
    4. The second row of the table is for the entries themselves. In the second row you have to add elements from the xml schema that are in the lower part of the element under which you inserted table. For example, under Transactionhistoryofheader - Btdocflowall - Item are then next nodes Btorder - Administrationheaderoneorder - Description. So in this case in first column will be displayed descriptions of all entries.
    5. At runtime rows are added dynamicly depending on actual number of entries.
    Regards.

Maybe you are looking for