Send multiple rows to database from a dynamic table.

I'm using JSP for my application. I have a table that changes
in size depending on a value a user selects in a drop down list.
They can then enter some values into the table and click the submit
button. I know for whatever reason Dreamweaver only sends the first
row to the database and I've had a hard time finding good
examples/tutorials showing how I could make it send all the rows to
the database.
Is there a way for me to just do a while/for loop taking into
account the number of rows in the table? That would be ideal for me
as it sounds like the simplest method and I'm very new to web
development.
Should I be using the Server Behavior Builder or a Stored
Procedure and if so is there any good examples for those as I've
had a hard time working with any documentation/tutorials I've found
regarding them.
Any help would be greatly appreciated.

Hey Baxter, thanks for the response. I guess I should have
been more specific when I said I was new to Web Development. I am
actually in Software Development where I primarily code in Java and
other OO languages. I have worked with a database before in java by
writing my own servlet. I have also done some HTML so jsp is very
good for me as it is mostly java with the odd bit of html
structuring with tables and such.
Languages like PHP and ASP I am not very familiar with and
most of the solutions I find for this very problem revolve around
ASP. I have just found it very hard to find a solution to this
problem. It seems like it isn't talked about very much even in
Dreamweaver's own documentation. If a stored procedure is the only
way to go then I think I can handle it with some guidance if anyone
knows of some tutorials/examples available.
Also is it really not possible to just go into the code and
somehow make it loop through each row in the table and execute a
prepared statement for each row? I've included some code of the
dynamic table I have and as you can see I have a Submit button on
its own outside of the table. If i had it inside then the user
would have to submit each row individually which isn't realistic
when there are many rows of data. Since the Submit is outside of
the while it only gets called once after the table is populated
thus sending only one row of data.
You might want to copy paste the code into a text editor as
some of the lines are long and may be hard to read here. If you
notice any errors in the table itself like mismatching column
headers it is because I changed some column names before attaching
it here so just assume that the table is all built correctly.
PS: I am going to be out of town for five days or so, so if I
don't reply to you right away don't think I disappeared from this
thread. Thanks again.
<div>
<h2>TableData</h2>
<form ACTION="<%=MM_editAction%>" METHOD="POST"
name="tabledata">
<table>
<% if (!Recordset1_isEmpty ) { %>
<tr>
<td class="head">Name1</td>
<td class="head">Name2</td>
<td class="head">Name3</td>
<td class="head">Code1</td>
<td class="head">Code2</td>
<td class="head">Old Status1</td>
<td class="head">New Status1</td>
<td class="head">Old Status2</td>
<td class="head">New Status2</td>
<td class="head">Year</td>
</tr>
<% } /* end !Recordset1_isEmpty */ %>
<% while
((Recordset1_hasData)&&(Repeat1__numRows-- != 0)) { %>
<% if (szin11 ==2) {color11 = "#ECECEC" ;szin11=(0);}
%><tr>
<td><input type="hidden"
value="<%=((((Recordset1_data =
Recordset1.getObject("Name1"))==null ||
Recordset1.wasNull())?"":Recordset1_data))%>" name="Name1"
/><%=(((Recordset1_data =
Recordset1.getObject("Name1"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%></td>
<td><input value="<%=((((Recordset1_data =
Recordset1.getObject("Name2"))==null ||
Recordset1.wasNull())?"":Recordset1_data))%>" name="Name2"
type="hidden" /><%=(((Recordset1_data =
Recordset1.getObject("Name2"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%></td>
<td><input value="<%=((((Recordset1_data =
Recordset1.getObject("Name3"))==null ||
Recordset1.wasNull())?"":Recordset1_data))%>" name="Name3"
type="hidden" /><%=(((Recordset1_data =
Recordset1.getObject("Name3"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%></td>
<input name="Code1" type="hidden"
value="<%=(((Recordset1_data =
Recordset1.getObject("Code1"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%>" />
<td><input value="<%=((((Recordset1_data =
Recordset1.getObject("Code2"))==null ||
Recordset1.wasNull())?"":Recordset1_data))%>" name="Code2"
type="hidden" /><%=(((Recordset1_data =
Recordset1.getObject("Code2"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%></td>
<td><input value="<%=((((Recordset1_data =
Recordset1.getObject("Old Status1"))==null ||
Recordset1.wasNull())?"":Recordset1_data))%>" name="Old Status1"
type="hidden" /><%=(((Recordset1_data =
Recordset1.getObject("Old Status1"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%></td>
<td><input size="10"
value="<%=((((Recordset1_data = Recordset1.getObject("New
Status1"))==null ||
Recordset1.wasNull())?"":Recordset1_data))%>" name="New Status1"
type="hidden" />
<%=(((Recordset1_data = Recordset1.getObject("New
Status1"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%></td>
<td><input name="New Status1" type="text" size="5"
/></td>
<td><input size="10"
value="<%=((((Recordset1_data = Recordset1.getObject("Old
Status2"))==null ||
Recordset1.wasNull())?"":Recordset1_data))%>" name="Old Status2"
type="hidden" />
<%=(((Recordset1_data = Recordset1.getObject("New
Status2"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%></td>
<td><input name="New Status2" type="text" size="5"
/></td>
<td><%=(((Recordset1_data =
Recordset1.getObject("Year"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%>
<input name="Year" type="hidden"
value="<%=(((Recordset1_data =
Recordset1.getObject("Year"))==null ||
Recordset1.wasNull())?"":Recordset1_data)%>"
/></td></tr>
<% if (szin11 ==0) {color11 = "#FFFFFF"; szin11=(0);}
%>
<% szin11++; %>
<%
Repeat1__index++;
Recordset1_hasData = Recordset1.next();
%>
</table>
<p>
Comments<br />
<textarea name="comments" cols="40"
rows="4"></textarea>
</p>
<p>
<input type="submit" value="Submit" />
</p>
<input type="hidden" name="MM_insert" value="tabledata"
/>
</form>
</div>

Similar Messages

  • Insert multiple rows into dB from one dynamic HTML form problem

    Hi,
    - I have form which has dynamically generated text fields so I don't want to hard code the field names into the servlet
    - A user will fill in one or more of the text boxes with a number and submit to the servlet (the name of the field represents an item ID, the value represents a quantity the user wants of that item).
    - The servlet needs to insert a new record into a table for each field that is not null.
    My question is how!
    If I send as an array or string, how will the servlet know that each submitted field needs to be inserted as a new record as opposed to one long record?
    I know I'll need to use a loop of somekind; how will I know how long to loop for if the number of 'not null' fields is not static? I need to get a value for the number of 'not null' fields from the form before the loop starts I think but don't know how...
    Also, should I call an SQL procedure that has an insert-loop OR should I have the servlet loop a call to a single insert statement? (am I making sense!?)
    Anyway, I've seen many examples where a submitted form updates/inserts one record into a table but never any for multiple records at one time. I'm using a Tomcat/Oracle set up, and I'm "New to Java"...
    Many thanks in advance.

    sorry, but I dont' understand very well what do you want to do!
    In any case if you want to retrieve all parameters (and you don't know what they are), you can use a general cosde like this:
    Enumeration names= request.getParameterNames();
    while(names.hasMoreElements()) {
    // in 'name' you store the name of the parameter
    String name = (String) names.nextElement();
    // in 'value' you store it's value
    String value = request.getParameter(name);
    remember that ALL parameter values can't be null (if they are void their value is "").
    The only case that you can get a null value is when you try to access a non existing parameter (like request.getParameter("pwqjsak"));
    I hope this helps! Else try to give me more info about your problem

  • Update multiple rows with datas from the same table

    i have a table like
    name version value1 value2
    2 A 4,31 3,5
    3 A 3,45 10
    2 B 6,97 12
    4 B 12 16
    so name + version is unique
    i have to update the datas value1 and value2 ( version A) with the datas from version B where the name ( VersionA) = name version B
    i.e the result should be
    name version value1 value2
    2 A 6,97 12
    3 A 3,45 10
    2 B 6,97 12
    4 B 12 16
    is it possible to do this in sql? ( sql. 8.1)

    ... if your table does not contain exactly what you expect you could get:
    'single row sub-query returns more than one row'
    To prevent that, put a unique index on (name, version). If this combination is not always unique, you will need to cater for the possibility in the update statement.

  • [Forum FAQ] How do I send multiple rows returned by Execute SQL Task as Email content in SQL Server Integration Services?

    Question:
    There is a scenario that users want to send multiple rows returned by Execute SQL Task as Email content to send to someone. With Execute SQL Task, the Full result set is used when the query returns multiple rows, it must map to a variable of the Object data
    type, then the return result is a rowset object, so we cannot directly send the result variable as Email content. Is there a way that we can extract the table row values that are stored in the Object variable as Email content to send to someone?
    Answer:
    To achieve this requirement, we can use a Foreach Loop container to extract the table row values that are stored in the Object variable into package variables, then use a Script Task to write the data stored in packages variables to a variable, and then set
    the variable as MessageSource in the Send Mail Task. 
    Add four variables in the package as below:
    Double-click the Execute SQL Task to open the Execute SQL Task Editor, then change the ResultSet property to “Full result set”. Assuming that the SQL Statement like below:
    SELECT   Category, CntRecords
    FROM         [table_name]
    In the Result Set pane, add a result like below (please note that we must use 0 as the result set name when the result set type is Full result set):
    Drag a Foreach Loop Container connects to the Execute SQL Task. 
    Double-click the Foreach Loop Container to open the Foreach Loop Editor, in the Collection tab, change the Enumerator to Foreach ADO Enumerator, then select User:result as ADO object source variable.
    Click the Variable Mappings pane, add two Variables as below:
    Drag a Script Task within the Foreach Loop Container.
    The C# code that can be used only in SSIS 2008 and above in Script Task as below:
    public void Main()
       // TODO: Add your code here
                Variables varCollection = null;
                string message = string.Empty;
                Dts.VariableDispenser.LockForWrite("User::Message");
                Dts.VariableDispenser.LockForWrite("User::Category");
                Dts.VariableDispenser.LockForWrite("User::CntRecords");     
                Dts.VariableDispenser.GetVariables(ref varCollection);
                //Format the query result with tab delimiters
                message = string.Format("{0}\t{1}\n",
                                            varCollection["User::Category"].Value,
                                            varCollection["User::CntRecords"].Value
               varCollection["User::Message"].Value = varCollection["User::Message"].Value + message;   
               Dts.TaskResult = (int)ScriptResults.Success;
    The VB code that can be used only in SSIS 2005 and above in Script Task as below, please note that in SSIS 2005, we should
    change PrecompileScriptIntoBinaryCode property to False and Run64BitRuntime property to False
    Public Sub Main()
            ' Add your code here
            Dim varCollection As Variables = Nothing
            Dim message As String = String.Empty
            Dts.VariableDispenser.LockForWrite("User::Message")
            Dts.VariableDispenser.LockForWrite("User::Category")
            Dts.VariableDispenser.LockForWrite("User::CntRecords")
            Dts.VariableDispenser.GetVariables(varCollection)
            'Format the query result with tab delimiters
            message = String.Format("{0}" & vbTab & "{1}" & vbLf, varCollection("User::Category").Value, varCollection("User::CntRecords").Value)
            varCollection("User::Message").Value = DirectCast(varCollection("User::Message").Value,String) + message
            Dts.TaskResult = ScriptResults.Success
    End Sub
    Drag Send Mail Task to Control Flow pane and connect it to Foreach Loop Container.
    Double-click the Send Mail Task to specify the appropriate settings, then in the Expressions tab, use the Message variable as the MessageSource Property as below:
    The final design surface like below:
    References:
    Result Sets in the Execute SQL Task
    Applies to:
    Integration Services 2005
    Integration Services 2008
    Integration Services 2008 R2
    Integration Services 2012
    Integration Services 2014
    Please click to vote if the post helps you. This can be beneficial to other community members reading the thread.

    Thanks,
    Is this a supported scenario, or does it use unsupported features?
    For example, can we call exec [ReportServer].dbo.AddEvent @EventType='TimedSubscription', @EventData='b64ce7ec-d598-45cd-bbc2-ea202e0c129d'
    in a supported way?
    Thanks! Josh

  • How  to delete(remove) one row(record) from a dynamic table

    Hi,
    I have adynamically created table.
    I want to delete 1 record(Row) from that Dynamic table.
    Say if my dynamic table contains 5 records(rows);after deletion of 1 record(1 complete row)from that dynamic table,the number of records(rows) should be 4 .
    Please suggest me how to proceed.
    Please provide me some sample code.Its not working
    I tried with these code:-Its not working-->
    IPrivateExportexView.IEt_WriteoffNode node=wdContext.nodeEt_Writeoff();
    IPrivateExportexView.IEt_WriteoffElement nodeEle= node.createEt_WriteoffElement(new Zfrm_Writeoff_P());
    node.removeElement(nodeEle);
    Please suggest
    Thanks
    -Sandip

    Hi,
    *int n=wdContext.nodeTable().getLeadSelection();*
    *wdContext.nodeTable().removeElement(wdContext.nodeTable().getTableElementAt(n));*   
    Further more , an example is given below for better understanding , do modifications according to your need.
    node :
           value node - Table (cardinality - 0..n , selection 0..1)
                              no    ( value attribute - string  )
                              name (value attribute - string )
       // create node elements 
         for(int i=0;i<5;i++)
        IPrivateClearnodeElements.ITableNode node = wdContext.nodeTable();
        IPrivateClearnodeElements.ITableElement ele = node.createTableElement();
        ele.setNo((101i)"");
        ele.setName("name :"(i1));
        node.addElement(ele);
    // Apply template Table -- select -- table node  or
    // create a table UI element and set the property Datasource - Table ( of the context)  
                             Insert Colum , in that column, next insert celleditor , of type text view  , bind the property text -- to "name " of Table node of the context
               Insert Colum , in that column, next insert celleditor , of type text view  , bind the property text -- to "no " of Table node of the context
    // create a action "removeElement"
    // create a button "Remove Element "  --> Event action -- removeElement
    // under the action write down the code :
    public void onActionremoveElement(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent )
        //@@begin onActionremoveElement(ServerEvent)
        // before removing display elements
        wdComponentAPI.getMessageManager().reportSuccess("Before  deletion :");
         for(int i=0;i<wdContext.nodeTable().size();i++)
             wdComponentAPI.getMessageManager().reportSuccess(wdContext.nodeTable().getTableElementAt(i).getNo()) ;
         wdComponentAPI.getMessageManager().reportSuccess(wdContext.nodeTable().getTableElementAt(i).getName()) ;
        int n=wdContext.nodeTable().getLeadSelection();
        wdContext.nodeTable().removeElement(wdContext.nodeTable().getTableElementAt(n));
       // After deletion
        wdComponentAPI.getMessageManager().reportSuccess("After deletion :");
             for(int i=0;i<wdContext.nodeTable().size();i++)
                   wdComponentAPI.getMessageManager().reportSuccess(wdContext.nodeTable().getTableElementAt(i).getNo()) ;
                   wdComponentAPI.getMessageManager().reportSuccess(wdContext.nodeTable().getTableElementAt(i).getName()) ;
        //@@end
    If helpful , give points .
    Let me know if any problem u face .
    Thanks,
    Srini

  • How to Send Multiple Plot XY Graph from LabVIEW to Microsoft Excel

    The link below describes exactly what I would like to do, however the link to the solution/work around does not work.
    Has anyone got an alternative solution?
    http://digital.ni.com/public.nsf/allkb/CFD30D5E9C01AB5386256CFB0082AF3E

    Please check the link again as it seems to be working fine now.
    How to Send Multiple Plot XY Graphs from LabVIEW to Microsoft Excel:
    http://digital.ni.com/public.nsf/allkb/CFD30D5E9C01AB5386256CFB0082AF3E
    The standard Excel Insert Graph.vi cannot insert multiple XY Graphs to Microsoft Excel, so you will need to use the Report Generation Toolkit for Microsoft Office.  You will find a link to an example program at the bottom of the page.  I have also attached it below.
    Attachments:
    example.zip ‏35 KB

  • Capturing data from a dynamic table that span multiple pages

    I created a PDF form that contained a dynamic table that can span across multiple pages. Additional rows in the table can be created by the person filling the form as and when needed.
    The PDF form is distributed to the receipient using Adobe LiveCycle Designer.
    However, when the form is "Submitted" back to the originator of the form, only data in the first row of the table is captured in the Response file. All the other rows are left out.
    I would be grateful if anyone can advise me as to how do I or what shall I do to get all the data in all the rows in the table into the Response File?
    Thank you.

    Hi
    Attached are the saved completed PDF-Form and the response file after the completed form has been submitted. I have copied this message to your gMail account.
    Only data in the first row of the table is captured in the Response file.
    If it is working correctly on your side, please let me know what could have gone wrong on my side.
    Thank you.
    Best regards,
    Kim-Siang Ng
    http://www.tipstoenrichyourlife.com/parenting
    With the wish to help all beings, may all my thoughts,words,and actions be void of attachment and ego.
    May they arise from compassion and wisdom.
    May they be imbued with patience and joy.
    The information contained in this transmission may contain privileged and confidential information and is intended only for the use of the person(s) named above. If you are not the intended recipient, any review, dissemination, distribution or duplication of this communication is strictly prohibited. If you received this email in error, please contact the sender immediately by reply e-mail and destroy all copies of the original message. This email is not intended as an offer or solicitation for the purchase or sale of any financial instruments.
    This email is forwarded automatically to a selected list of my buddies for enjoyment. Contents come from various sources and none of the materials I claim as my property. If any belongs to you, please consider it an honor that the content was worthy enough to be shared. No copyright infringement intended!. If any material is not appealing to you DELETE immediately.
    When forwarding this email, please have the courtesy to respect the privacy and confidentiality of the sender by deleting all previous email trails and addresses before you proceed to forward this email to others.

  • Sending multiple rows to result set

    Hi,
    I want multiple rows to be returned from my pl/sql procedure without using cursor?can I do it? Is there any package for this?
    also When I use cursor variable how do I capture that return values?
    regards
    ragh

    First Question:
    grin. One really big string and a custom parser.
    Seriously... I read something about PL/SQL tables being supported in a late/future release... is that true? Do we still use a ref cursor, or can we pass VARRAYS somehow back to Java?
    Third question:
    Posted earlier by Mark Tomlinson:
    This one does it all. Nothing JDeveloper specific here, all JDBC.
    * This sample shows how to call a PL/SQL function that opens
    * a cursor and get the cursor back as a Java ResultSet.
    import java.sql.*;
    import java.io.*;
    // Importing the Oracle Jdbc driver package makes the code more
    readable
    import oracle.jdbc.driver.*;
    public class retrefcur_samp
    public static void main (String args [])
    // throws SQLException
    try
    // Load the driver
    DriverManager.registerDriver(new
    oracle.jdbc.driver.OracleDriver());
    // Connect to the database
    // You can put a database name after the @ sign in the
    connection URL.
    Connection conn =
    DriverManager.getConnection ("jdbc:oracle:oci8:@ora8tst",
    "scott", "tiger");
    // Create the stored procedure
    init (conn);
    // Prepare a PL/SQL call
    CallableStatement call =
    conn.prepareCall ("{ ? = call java_refcursor.job_listing
    // Find out all the CLERKs person
    call.registerOutParameter (1, OracleTypes.CURSOR);
    call.setString (2, "*");
    call.execute ();
    OracleResultSet rset = (OracleResultSet)call.getObject (1);
    // Dump the cursor
    while (rset.next ()){
    System.out.println (rset.getString ("JOB"));
    rset.close();
    call.close();
    } catch(SQLException esql) {
    System.out.println("Trouble in river city ");
    System.out.println(esql.toString());
    // Utility function to create the stored procedure
    static void init (Connection conn)
    throws SQLException
    Statement stmt = conn.createStatement ();
    stmt.execute ("create or replace package java_refcursor as "
    +
    " type myrctype is ref cursor return
    EMP%ROWTYPE; " +
    " function job_listing (j varchar2) return
    myrctype; " +
    "end java_refcursor;");
    stmt.execute ("create or replace package body java_refcursor
    as " +
    " function job_listing (j varchar2) return
    myrctype is " +
    " rc myrctype; " +
    " begin " +
    " open rc for select * from emp; " +
    " return rc; " +
    " end; " +
    "end java_refcursor;");
    stmt.execute ("create or replace package java_ref_clean as "
    +
    " type myrctype is ref cursor; " +
    " function cleanup (cc myrctype) return
    number; " +
    "end java_ref_clean;");
    stmt.execute ("create or replace package body java_ref_clean
    as " +
    " function cleanup (cc myrctype) return number
    is "+
    " result number; " +
    " begin " +
    " close cc; " +
    " end; " +
    "end java_ref_clean;");
    null

  • How to send multiple row data into an internal table??

    I have a view with table control.i want to select multiple row and send all the row data into an internal table.i am able to select multiple row but all the selected row data is not going to the internal table.....only a particular row data which is lead selected is going.
    Do anyone can help me regarding this issue?
    Thanks in advance,
    Subhasis.

    Hey,
    Some code example:
    declaring an internal table and work area to get all the elements from the node.
    data : lt_Elements type  WDR_CONTEXT_ELEMENT_SET,
             ls_Element type  WDR_CONTEXT_ELEMENT_SET,
    considering flights is my node.
             lt_data type sflight.
    Node_Flights is the ref of the node to which ur table is binded.
    Use Code Inspector to read the node.
    lt_Element = Node_Flights->GET_ELEMENTS
    loop at lt_elements into ls_Element.
    l_bollean =   ls_elements->is_selected ( returns abap true/false ).
        if l_bollean IS INITIAL.
           append ls_Element to lt_data.
       endif.
    Hope this would help.
    Cheers,
    Ashish

  • How can I send multiple pics to email from my iPhone 5

    How can I send multiple pics from photos app on I phone 5 to an e mail?

    Open the album or event folder on your iPhone.  Click the "arrow" icon in the upper right side of your screen.
    Click the pictures you'd like to share via email (they will show a little checkmark when selected).
    Click the "share button at the lower left corner of your screen...
    Taa daa!
    Bob

  • Inserting Multiple Rows into Database Table using JDBC Adapter - Efficiency

    I need to insert multiple rows into a database table using the JDBC adapter (receiver).
    I understand the traditional way of repeating the statement multiple times, each having its <access> element. However, I am just wondering whether this might be performance-inefficient, as it might insert records one by one.
    Is there a way to ensure that the records are inserted into the table as a block, rather than record-by-record?

    Hi Bhavesh/Kanwaljit,
    If we have multiple ACCESS tags then what happens is that the connection to the database is made only once. But the data is inserted row by row.
    Why i am saying this?
    If we add the following in JDBC Adapter..logSQLStatement = true. Then incase of multiple inserts we can see that there are multiple
    <i>Insert into tablename(EMP_NAME,EMP_ID) VALUES('J','1000')
    Insert into tablename(EMP_NAME,EMP_ID) VALUES('J','2000')</i>
    Doesnt this mean that rows are inserted one by one?
    Correct me if i am wrong.
    This does not mean that the transaction is not guaranted. Either all the rows will be inserted or rolled back.
    Regards,
    Sumit

  • Call tp EP and sending multiple rows of records

    Hello friends,
    I am creating a screen and am sending back to EP an user ID.
    However I would like to send Multiple User-Ids.
    Below is the code of what AM I doing.
             str = userid.    " NOTE - I would like to send Multiple IDS.
             lv_value_label->set_string_struct_element( element = str
                                                        label_name = 'MAINTID' ).
           it_result_state-result_state = 'APPROVED'.
           APPEND it_result_state TO it_result_states.
           CALL METHOD eup_structure_factory=>pack_value_label_to_xml
             EXPORTING
               iv_value_label = lv_value_label
             IMPORTING
               ev_xml         = str.
           CALL FUNCTION 'EUP_STORE_BSP_OUTPUT_DATA'
             EXPORTING
               iv_process_id    = process_id
               iv_task_id       = task_id
               iv_output_value  = str
             TABLES
               it_result_states = it_result_states.

    Dear Ster,
    I think you are having all the user id's in an internal table.
    Why dont you loop your internal table and pass those values in the standard FM you represented ('EUP_STORE_BSP_OUTPUT_DATA').
    I'm not aware that, whether there is any Standard FM's to be used for sending multiple user ID's. Will check and let you know.
    Hope this will be helpful.
    Regards,
    Gokul.N

  • Update multiple rows of DSO from Datasource

    Hi,
    We have a custom DSO with 4 key characteristics.  It is initially populated by a custom datasource correctly.
    We now need to update some of the data fields using a standard datasource, but it only has two of the key fields available.
    In the transformation from the datasource to this DSO, I have generated an internal table in the start routine to collect the additional two key fileds from the DSO table. 
    I was wondering if there is a way to loop through when loading to update all the rows for the other two keys?
    e.g.
    DSO - load from custom datasource:
    K1  K2  K3  K4  D1 D2
    a    b     c    d     1   2
    a    b     e    f      3   4
    standard datasource
    K1 K2   D2
    a   b      8
    We would like to use the data from the standard datasource to update both rows in the DSO to populate data column D2 with the value 8.
    Thanks!
    Darryl

    Darryl,
    In case you dont want to create a new DSO, you can try this option.
    Add the infosource between the standrad data source and DSO and this infosource should have the structure same
    as the DSO.
    The transfermations between DS and Infosource should be 1 to 1, But in the start routine of the transfermations between infosource and DSO , write the following logic.
    - Declare an 2 internal tables same as the source_package.
    - Read the DSO active table with key1 and key2 from source_package into the internal table1 declared above.
    - Copy source_package contents to internal table2.
    -  delete the contents of source package.
    -  Loop at internal table 1 and populate key3 and key4 by reading internal table2.
    -  Modify source_package from internal table1.
    Thanks,
    Ravi.

  • How to add a row to database  from tableModel

    hi friends,
    i wnt to know that is it possible that when i add some rows in a table which has been created by a table model to add those rows to database like what happen in MS Access when u add rows and close the window the rows are automatically added to database
    i want to know where to add the listener for that and which listener to use ?

    thanks Andre,
    but i have solved my problem in a different way, i have used
    method SetValueAt() of AbstractTableModel which i have used to
    create the table
    actaully my question was little confusing, i wanted
    to add rows as soon as the user has finished entering
    a new row...it would be better if it could be done for
    every cell but that would be more complex...

  • Count MySQL rows based off Value in Dynamic Table

    Greetings all. I have 2 MySQL tables; 1 that contains the names of my classes.(Class A, Class, B, etc.) and 1 table that contains the names of students in each Class (for example Class A: John Doe; Class A: Susie Smith.; Class B: Jane Doe). In the 2nd table the Class name is in its own column and the student's name is in a 2nd column.
    I currently have a dynamic repeating table that lists the names of all of the classes from the 1st table. What I'm trying to do is add a second column to this repeating dynamic table that lists the number of students in each class. For example; Row 1 of the dynamic table would say "Class A | 5; Class B | 3; Class C | 7, etc.). The dynamic table works perfectly to list the class names. For the life of me I can't figure out how to perform a count for each class to insert in the repeating table. I will be adding more Classes which as why I'm trying to set up the counting query dynamically. So far I have only been able to figure out how to count the total rows in the 2nd table, or count the rows with a specified class name. Any advice or guidance on how to count the number of rows in the 2nd MySQL table based off the class name in the repeating table is much appreciated. Thank you for any and all help. Have a great day.

    Select count(*), Class from MyTable
    Group by Class
    Time to learn about SQL:
    http://www.w3schools.com/sql/sql_intro.asp

Maybe you are looking for

  • Automatic posting in GL Master record

    Dear All:              I want to know that can automatic posting tick in GL Master be made optional for certain users. I mean i am a power user of FI,but i share my login with GM Finance so what happens whenever he wants to make direct entry into cer

  • Exception in Payment Proposal - Pmnt methods for this run are not specified

    Dear all, I want to ask if it is possible to run a payment proposal for AP transactions together with AR. The AR line items are used for clearing. Actually, this is the first time we execute proposal run which contains AP and AR respectively. And dur

  • Cannot connect HP to Airport Express

    I have hooked up my airport express and it connects fine with my Mac. I have been trying to connect to the wireless internet connection also with my HP and having no success. It finds the network, connects to it, but not to the internet. Any help wou

  • Where Clause in Auto DML Fetch

    Hi all, Is it possible to restrict the data that is being returned by an automatic DML process? I have a case where I've built a master detail form that I navigate to when I select a node from a tree. If the node I chose is of a type of "x" then I on

  • Block Payment

    Dear Experts, Is there any way to block a particular Vendor from posting Down-payments (Special GL). please help. Edited by: Hussein  Merchant on Dec 31, 2009 4:18 PM