How to Auto generate "order_id"

I want to Auto generate "order_id" No with sysdate and sequence through pre-insert trigger.
for example:
when user commit transaction 1st time today that auto generate this No
020220101
when 2nd time commit transcation generate this
020220102
3rd time commit transcation generate this
020220103
4th time commit transcation generate this
020220104
when user will commit transaction tomorrow 1st time generat this
030220101
when 2nd time commit transcation generate this
030220102
3rd time commit transcation generate this
030220103
4th time commit transcation generate this
030220104
anyone can help me.

Hi,
Try the following code.
SELECT TO_CHAR(SYSDAYE, 'DDMMRRRR') || NVL(MAX(TO_NUMBER(SUBSTR(ORDER_ID, 9))), 0) + 1 INTO :<block_name>.<field_name> FROM <table_name> WHERE SUBSTR(ORDER_ID, 1, 8) = TO_CHAR(SYSDAYE, 'DDMMRRRR');Regards,
Manu.
If my response or the response of another was helpful, please mark it accordingly

Similar Messages

  • How to "auto" generate "Primary Key" in custom table?

    Hi Folks,
    Requirement:
    I need a function module or program that can create automatically a primary key.
    Scenario:
    I have a program that creates an entries and save it to a custom table at the same time, but a primary key should always be generated respective to the entries saved.
    Example:
    Material(MATNR) 4001001, Plant(WERKS) XX01, ID[Primary Key-auto generated]
    (I'm thinking of a similar concept/logic on how a unique IDOC number is being generated or how SAP standard creates a unique entry)
    I try to look for any SAP FM that can generate a PK, but there's no luck.
    Thanks.
    Regards,
    Jun

    Hi Keshu and All,
    The links are helpful, however:
    #1. I don't have authorization to create a new object in transaction SNRO, but the way I see the objects in SNRO is just for defining the length(number of characters) for the ranges that will be use if I'm not mistaken.
    #2. FM NUMBER_GET_NEXT - yes it can populate incremental unique entries but it's only occurring at runtime ?? So when the program get terminated it's not being saved nowhere.
    So after if I use FM NUMBER_GET_NEXT, I always have to look for all the last primary key in my custom table, then target it as my starting point for creating a new PK.  I think this will give a performance issue, any comments?
    For better visualization, I have scenario:
    1.  (ZQ_CREATE_PK) Create unique incremental PK for material, batch, so on..
    2.  Append line/entries to ZQ_TABLE
    3.  Repeat #1 and #2
    4.  User exits the program
    5.  Back to 1 --> At this point, I need to get the "LATEST" PK then start this as a starting point again to generate PK and append it to ZQ_TABLE
    I'm assuming that SAP has other SAP FMs related in creating this scenario.   Similar to IDOC # creation..
    Thanks.

  • How to auto generate a sequence.

    Dear all
    The entity Object "OrderEntryEO" has an attribute called"OrdNumber" that indicates the reference number of the order number. the order number is compose be a sequence on the year. For example 1/2011 , 2/2011 , 3/2011 and so on..
    this sequence must be auto generated when pressing save button.
    I have generated the entityImpl java class "OrderEntryEOImpl.java . with accessors , DO_DML method and create method.
    these are the methods
    {code}
    protected void create(AttributeList attributeList) {
    super.create(attributeList);
    {code}
    {code}
    protected void doDML(int operation, TransactionEvent e) {
    super.doDML(operation, e);
    {code}
    Can any one please help me how to Implement this in java code
    Regards

    I wanted to clear up what I consider to be some misinformation on this thread.
    Database sequences, regardless of what magic you try (including setting the cache size to 1) can and will, by their very design have gaps. I don't care if you are doing a web app, a client server app, an SOA app, or any other newfangled or old-fashioned, red screens, green screens, blue screens - DATABASE SEQUENCES IN ORACLE CAN AND WILL HAVE GAPS.
    There is only one way to ensure gap-free sequence numbers upon insert:
    * You must lock the table or use some other device to serialise inserts.
    Any other technique you want to use will not work in a multi-user environment. I'm not going to go through the proof of it here because it's been discussed ad-infinitum (search on asktom.oracle.com if you want to see all of the crazy failed attempts to do it without serialisation). You can also read on asktom about some other techniques (such as assigning the numbers after the fact) that you could consider.
    Bottom line to remember however, Oracle Database Sequences are not and cannot be gap free (at least as of today, the 4th of April, 2011 AD at 08:48 GMT +1)
    John

  • How to auto generate SFC Number(using the Old SFC Num) when I split a SFC

    when I split a SFC (SFC Number:A001), I want to auto generate  the new SFC number, and the new SFC number pattern is A001-01 (the prefix is old SFC number). I don't know how to do.
    Please help me if you  know  it.

    Wenjun,
    SFC ID is actually a key field so I would suggest you following [Note 1363812|https://service.sap.com/sap/support/notes/1363812] "SAP ME 5.2: Key Field Character
    Restrictions" to use only legal characters in Next Number patter. If the system does not generate serialized SFCs in accordance with the patter even in this case, then it is definitely a bug.
    Per on-line help: "SFC Number Serialize - the pattern that uniquely identifies the serialized SFC number during serialization, split, or relabel"
    Sergiy

  • How to auto-generate a "empno" field at run time in oracle forms 6i

    Hello!
    I have connected to a SCOTT schema. And i am using emp table. At run time mode when i press F8 then the data is displayed in the fields.
    My task is to generate auto "empno" as soon as i run the form. Kindly do the needful.
    Thanks in advance

    Hi Francios,
    I think with your solution our user only able to see the current information in the form.I donot think it will auto generate the empno.
    Dear user,
    I suggest what you can do is to create one sequence in your database and use it to generate automatic
    empno.
    In post query trigger try to implement the idea.
    Suppose in the name of the sequence is empno_seq.
    if emp.empno is null then
    :emp.empno := empno_seq+1;
    end if;
    Try i hope it will work
    Regards
    Rajat

  • How to auto generate a different JPanel name or u guys have other ways

    displayPanel = new DisplayPanel();
              count++;
              String frameName = "Frame " + Integer.toString(count);
            iframe = new JInternalFrame(frameName, true, true, true, true);
            iframe.add(displayPanel);    
            iframe.setBounds(20, 20, 150, 100);
            iframe.setVisible(true);      
            jDesktopPane1.add(iframe);
            iframe.setToolTipText("Internal Frame");
            iframe.toFront();
            iframe.setName(frameName);with this coding, it is using the same displayPanel.
    I would like to let the user to press a ADD button and generate a internal frame with panel.
    How can i generate a different this panel with different name like displayPanel1, displayPanel2 and unlimited.
    The reason i wanna different name because i wan to call it out the displayPane.
    I can call it those different jInternalFrame. But how can i call it those inside jInternalFrame`s displayPane?
    Edited by: LxKaneShiro1 on Jul 6, 2008 4:51 PM

    LxKaneShiro1 wrote:
    displayPanel = new DisplayPanel();
    count++;
    String frameName = "Frame " + Integer.toString(count);
    iframe = new JInternalFrame(frameName, true, true, true, true);
    iframe.add(displayPanel);    
    iframe.setBounds(20, 20, 150, 100);
    iframe.setVisible(true);      
    jDesktopPane1.add(iframe);
    iframe.setToolTipText("Internal Frame");
    iframe.toFront();
    iframe.setName(frameName);with this coding, it is using the same displayPanel.
    I would like to let the user to press a ADD button and generate a internal frame with panel.
    How can i generate a different this panel with different name like displayPanel1, displayPanel2 and unlimited.Any time you see "this" in code, it refers to the object that line of code is in context for--the current object. You cannot change that.
    The reason i wanna different name because i wan to call it out the displayPane.
    I can call it those different jInternalFrame. But how can i call it those inside jInternalFrame`s displayPane?You do not need a name to "call" a Frame, you just need a reference to it:
    myFrame f = new myFrame();"f" contains the reference to your Frame and can be used as you need. If you need another Frame:
    myFrame f2 = new myFrame();"f2" now contains reference to a totally separate Frame.

  • Auto generate employee/applicant number

    Hi All
    I want to auto generate the employee and applicant number as follows:
    ABCW0000001
    ABCS00000001
    Where first 3 characters i.e., ABC stands for the company name and fourth characters i.e., W stands for Workers and followed by the employee number.
    The category of employee i.e., Staff or Worker is captured in the People Group segment in assignments.
    I can write a fast formula to auto generate the employee numbers, but as employee number has to be generated first before updating the assignments.
    How to auto generate the numbers before updating the assignments?
    Thanks in advance for any help.
    Regards
    Rahman

    Hi
    Do you have multiple assignments over there?There are no multiple assignments.
    If not, can you move the people group segment to the people screen?How can I move this to People Screen?
    What should be the empl number if the people group changes anyway?If the employee gets promoted, say from worker to staff, then a new number should be generated from the date of new assignment. Also the old number should not be used in future.
    Thanks for the help.
    Regards
    Rahman

  • 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 can I forward a email without the extra info auto generated by Thunderbird ?

    When I foward a emai, Thunderbird auto-generates lots of extra information that is not need to be seen by the person I am forwardind to the message.
    How can I configure Thunderbird forward to clean all the extra info auto generated by Thunderbird ?
    Best regards
    HC

    ''Airmail [[#answer-708174|said]]''
    <blockquote>
    From the menu bar select View-Headers and set it to Normal instead of All.
    The mail system generates all this info and not Thunderbird FYI.
    </blockquote>
    SOLVED ! :)
    Thank you very much for your help :)
    HC

  • 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)

  • How to Create a Auto Generated number with some preceding text in Sharepoint 2010

    I am trying to create a auto generated number field in Sharepoint 2010 list item. My requirement is to have the following format number generated when new request is created in Sharepoint using form. Auto generated Ticket ID should be in the following format
    "IR13000" "IR13001" "IR13002"....... Please let me know how to get this done. I tried to use combination of default ID and Characters but its not working for new requests, its only reflecting for existing uploaded requests. I
    am trying this for taking up Ticket requests by filling up some fields in the form. Any quick help is much appreciated.
    Thanx

    Here are the steps:
    1 - Open your SharePoint site in SP Designer 2010.
    2 - Click Workflows and add a List workflow. Associate this workflow on the list where you want the Random Text to be generated.
    3 - Inside the workflow editor, select the Action "Update list item"
    4 -  Select 'Current Item'.
    5 - Click Add.. and select the field which needs to be updated with the Random Text. Make sure this column is not of type "Calculated" type, otherwise you won't see it in the list of the fields within the workflow.
    6 - Click "..." button in the next textbox which will open String Builder dialog box.
    7 - Type IR and then click 'Add or Change Lookup and select ID column from "Field from source". Hit OK.
    8 - It should look like IR[%Current Item:ID%]
    9 - Hit OK.
    10 - Save and publish the workflow. (Please note that currently this workflow is not set to auto run on creating new items. That's because we want to test it at this point of time).
    11 - Go to your list in SharePoint and create a new item. After creating, select the item and click Workflows and then run this workflow.
    12 - You should be able to see the text "IR1" in the designated column.
    13 - Once you see that it's working, go to SPD and set the workflow to run automatically on creation of the new item. Save and publish and then return to your list in SharePoint.
    14 - Create a new item there and you should see the Random value in the column.
    15 - You will also see the column in the New form. In order to remove it, go to List settings > content types > Item content type > and select Hidden for this column so that it doesn't showup in any form.
    Try it and let me know how it goes.
    Thanks,
    Ashish

  • How to get auto generated column in spring jdbc

    Hi guys ,
    I am using springJDBC and sybase db.
    I think what i am facing is a standard problem but whatever support i am getting from google is not working.
    My problem is :
    "While inserting values in database one colum is autogenerated .....how do i get the value of that column??"
    FYI,
    I have tried using the following code :
    "final String INSERT_SQL = "insert into my_test (name) values(?)";
    final String name = "Rob";
    KeyHolder keyHolder = new GeneratedKeyHolder();
    jdbcTemplate.update(
    new PreparedStatementCreator() {
    public PreparedStatement createPreparedStatement(Connection connection) throws SQLException {
    PreparedStatement ps =
    connection.prepareStatement(INSERT_SQL, new String[] {"id"});
    ps.setString(1, name);
    return ps;
    keyHolder);
    // keyHolder.getKey() now contains the generated key"
    but i am getting this error : "java.lang.AbstractMethodError: com.sybase.jdbc2.jdbc.SybConnection.prepareStatement(Ljava/lang/String;I)Ljava/sql/PreparedStatement"
    I think this code works well with Oracle but not with sybase .........does anyone know the solution of this problem .......and by "this problem" i mean how to retrieve auto generate value in spring jdbc ...........without using SimpleJdbcInsert class

    Looking at the previous post it doesn't look like a Spring issue.
    You are using a JDBC driver which does not support getting generated keys so you have 2 choices:
    - Use a different driver that supports generated keys
    - Get the generated key by issuing some vendor specific SQL e.g. 'select @@identity' for SQL server

  • How to make the auto generated java script not to have any html comments.

    Hello BEA Experts, As you know that auto generated javascript functions like getNetuiTagNames in Workshop are included with in the the HTML comment tags like <b><!--
    --!></b> its another thing they should be generated correctly as follows <b><!--
    //--!></b>, to hide it from browsers not supporting javascript.
    My question is there any way to stop generation of the HTML comment tags and just genrate the javascript with in teh script elements..
    Please let me know..
    Thanks in advance..
    -Bob F.

    Not sure if this is an application question or if you are trying to hook into Crystal Reports parameter UI? If the later then no option other than report design. If an application then I can move this to the Java Forums.
    If you are asking how to alter the parameters I suggest you remove the Java reference and post a new question so it's not confusing the issue.
    Please clarify?

  • How can I customize the auto-generated WSDL when using a PL/SQL webservice?

    My webservice returns a refcursor as an ArrayOfString. (I followed the sample code.) Instead of everything being returned in one large array, I need to create a correct record hierarchy, like <rec1><fld1></fld1></rec1>, etc.
    As far as I know, this grouping has to be done in a WSDL file. However, following this sample, the WSDL is auto-generated and overwritten with each launch of the webservice.
    Am I missing something, or are there other secrets/tips?
    thanks

    Very Nice:) Thanks!
    1. I added this to my HTM HEADER:
    <script language="JavaScript" type="text/javascript">
    function test_javaprompt () {
    var Hours = prompt("How Many Hours?");
    $x('P142_HOURS').value = Hours;
    doSubmit()
    </script>
    2. I Created an Item:
    P142_HOURS
    3. I Created a Button:
    TEST_JAVA
    a. In the Button area for, Optional URL Redirect, I selected- Target is a URL
    b. URL Target- javascript:test_javaprompt();
    When I press the Button then it does Exactly what I want it to do.
    Except....
    Ultimately, I do not want this javascript assigned to the button.
    I would like to run this javascript when the value of a DatePicker Item, (P142_DROPS_SUBMITTED) is changed.
    If you can help me with that then I'll be forever grateful:)
    -Gary

  • How to remove an auto generated ActionPreformed Event from Netbeans?

    Hi,
    How do I remove an auto generated ActionPreformed Event from my code? I accidentally created one and want to remove it. I tried to right click on the event and refactor/delete all the dependencies in the source but it wouldn't let me remove it. There shouldn't be any DEPENDENCIES it was just created.
    Thanks,
    V$H3r

    NetBeans | Help | Help Contents | Java Applications | Building Java GUIs | Designing Java GUIs | Managing Component Events | Removing Event Handlers:
    1. In the Inspector window, select the component whose event handler you want to remove.
    2. Click the Events button at the top of the Properties window.
    3. Select the event in the property sheet and click the ellipsis (...) button to display the Handlers dialog box. Alternately, you can simply delete the name of the handler you want to remove in the Properties window.
    4. In the Handlers dialog box, select the handler to remove from the list and click Remove.
    When you remove an event handler, the corresponding code block is also deleted. If more than one handler uses the same name and same block of code, deleting a single reference to the code does not delete the code itself. Only deleting all references will delete the corresponding code block, and a confirmation dialog box is displayed first.

Maybe you are looking for

  • OSB Business -Proxy Service

    Hi, I need to call WSDL which has 2 operations. I need to pass default xml payload to operation 1 and the response I get, has to be passed to invoke operation 2. I have created 2 business services and after I create a proxy service : How to pass defa

  • NWBC for HTML Layout

    My nwbc for HTML, for one system, looks like this: The icons don't appear; I couldn't close the launchpad navigation, and appears masthead, end of masthead ammong other things in the shell. When it should look like this: Can anyone explain me why thi

  • How to create a content list for sections and chapters etc

    just started with Pages on iPad 2 and really like is BUT where is the control for creating a content list for a long document for chapetrs etc? thanks guys

  • Admin Console Not Displayed !!

    Help please ! This is a wierd problem. We cant get the admin console (port 7001) to come up in a browser. The browser just runs and runs and never displays an error message ... we were able to see the console a couple of days ago ... never saw anythi

  • Using E4X issue

    Hello, What I am trying to do is to show an Alert depending on if a certain attribute exists within my xml. I am getting the Alert to show up, but it is showing up for each selection I make in my comboBox(which shows formats from the xml) even though