How to compare two rows from two table with different data

how to compare two rows from two table with different data
e.g.
Table 1
ID   DESC
1     aaa
2     bbb
3     ccc
Table 2
ID   DESC
1     aaa
2     xxx
3     ccc
Result
2

Create
table tab1(ID
int ,DE char(10))
Create
table tab2(ID
int ,DE char(10))
Insert
into tab1 Values
(1,'aaa')
Insert
into tab1  Values
(2,'bbb')
Insert
into tab1 Values(3,'ccc')
Insert
into tab1 Values(4,'dfe')
Insert
into tab2 Values
(1,'aaa')
Insert
into tab2  Values
(2,'xx')
Insert
into tab2 Values(3,'ccc')
Insert
into tab2 Values(6,'wdr')
SELECT 
tab1.ID,tab2.ID
As T2 from tab1
FULL
join tab2 on tab1.ID
= tab2.ID  
WHERE
BINARY_CHECKSUM(tab1.ID,tab1.DE)
<> BINARY_CHECKSUM(tab2.ID,tab2.DE)
OR tab1.ID
IS NULL
OR 
tab2.ID IS
NULL
ID column considered as a primary Key
Apart from different record,Above query populate missing record in both tables.
Result Set
ID ID 
2  2
4 NULL
NULL 6
ganeshk

Similar Messages

  • How to delete multiple rows from ADF table

    How to delete multiple rows from ADF table

    Hi,
    best practices when deleting multiple rows is to do this on the business service, not the view layer for performance reasons. When you selected the rows to delete and press submit, then in a managed bean you access thetable instance (put a reference to a managed bean from the table "binding" property") and call getSeletedRowKeys. In JDeveloper 11g, ADF Faces returns the RowKeySet as a Set of List, where each list conatins the server side row key (e.g. oracle.jbo.Key) if you use ADF BC. Then you create a List (ArrayList) with this keys in it and call a method exposed on the business service (through a method activity in ADF) and pass the list as an argument. On the server side you then access the View Object that holds the data and find the row to delte by the keys in the list
    Example 134 here: http://blogs.oracle.com/smuenchadf/examples/#134 provides you with the code
    Frank

  • Find rows from a table with no Activities

    Hi,
    I have a ‘Data’ table in relation with a ‘Note’ table with a date and I would like to find all the rows in the ‘Data’ table that do not have any ‘Note’ taken in the the last 3 months (including no ‘Note’ at all)?
    THanks,

    Hi,
    934281 wrote:
    Thanks for the great and quick answers!
    Could someone tell me what is the difference between the 2 methodes (Not Exist vs Not In)?They can usually be used to get the same results. Sometimes, it's easier to understand the logic of one rather than the other. Use whichever one you prefer. I can't guarantee that the optimizer won't do exactly the same thing, regardless of which one you use.
    Also, I would I add in the Select the Date of the most recent Note and sort ASC so that I could have the Data that had not activity in the last 3 months and sorted by the one that had no activity the longest time ago first?In that case, I suggest a join, rather than either EXISTS or IN:
    WITH     got_r_num     AS
         SELECT     d.*
         ,     n.notedate
         ,     ROW_NUMBER () OVER ( PARTITION BY  d.id
                                   ORDER BY          n.notedate     DESC     NULLS LAST
                           )         AS r_num
         FROM           data        d
         LEFT OUTER JOIN      note        n  ON  n.dataid     = d.id
    SELECT       *     -- Or list all couumns except r_num
    FROM       got_r_num
    WHERE       r_num          = 1
    AND       NVL ( notedate
               , SYSDATE - 99     -- or any date more than 3 months ago
               ) <  ADD_MONTHS ( SYSDATE
                                  , -3
    ORDER BY  notedate
    ;If you'd care to post some sample data (CREATE TABLE and INSERT statements), and the results you want from that data, then I could test this.
    When you say you don't want dates within the last 3 months, I assume you're including dates in the future. (Future dates may be impossible in your table, anyway.)
    3 months can be as short as 89 days or as long as 92 days. I used ADD_MONTHS (sysdate, -3) to get exactly 3 months; you can use SYSDATE - 90 if that suits your needs.

  • How to return mismatched rows from two tables?

    I have created two tables in the same database as below which gives the row
    count of tables across all databases before and after an DB restore
    operation.
    create table before_restore(db_name varchar(100),table_name
    varchar(1000),row_count int) insert into before_restore exec sp_msforeachdb 'USE
    [?]; select ''?'' as database_name,o.name,max(i.rowcnt ) From [?].sys.objects o
    inner join [?].sys.sysindexes i on o.object_id=i.id where o.type=''U'' group by
    o.name'
    create table after_restore(db_name varchar(100),table_name
    varchar(1000),row_count int) insert into after_restore exec sp_msforeachdb 'USE
    [?]; select ''?'' as database_name,o.name,max(i.rowcnt ) From [?].sys.objects o
    inner join [?].sys.sysindexes i on o.object_id=i.id where o.type=''U'' group by
    o.name'
    I want to compare these two tables and it should only return me rows that
    have changed after the restore operation is complete.
    Eg:
    Table xyz has rowcount of 100 before restore and the restore was not proper
    and after restore count is 50. So it should return me the result set as
    below;
    Db_name    Table_Name  row_count_before_restore    row_count_after_restore
    abc                   xyz                       100                              
       50
    Thanks!!!

    Something like below perhaps? Btw, I recommend using catalog view and dynamic management views instead of the old system tables (now called compatibility views)...
    SELECT
    COALESCE(a.db_name, b.db_name) AS db_name
    ,COALESCE(a.table_name, b.table_name) AS table_name
    ,a.row_count AS row_count_before_restore
    ,b.row_count AS row_count_after_restore
    FROM before_restore AS b FULL OUTER JOIN after_restore AS a ON b.db_name = a.db_name AND b.table_name = a.table_name
    WHERE b.row_count <> a.row_count OR b.db_name IS NULL OR a.db_name IS NULL
    Tibor Karaszi, SQL Server MVP |
    web | blog

  • I need to retrieve the a set of rows in between two rows from a table.

    consider employees table and primary key employee_id.
    With out using EMPLOYEE_ID column in the where clause or between clause, I need to get the records between 104 and 116 or a set of records between two rows.
    Can any one help me in this... i know this is simple but am just a fresher to oracle development... help me grow....
    Thanks,
    Arun

    ya at last i got the out put... thank guys for thinking with me....
    SELECT rownum, employee_id FROM (SELECT rownum, employee_id FROM employees ORDER BY employee_id)
    WHERE ROWNUM <=8
    MINUS
    SELECT rownum, employee_id FROM (SELECT rownum, employee_id FROM employees ORDER BY employee_id) WHERE ROWNUM <= 4

  • How to modify a row from a table?

    Hi experts!
    I've a doubt, I need to modify a table with some information I've search, if I do the code below, my program works slowly because the tabla ITDATOS has 650 rows... so, the problem is, how can I modify this in another way?
    FORM RELLENA_DATOS_GENERALES USING PERSONAL.
    DATA: UNIDAD TYPE P0001-ORGEH.
    DATA: TEXTO TYPE HRP1000-STEXT.
    data: indice type sy-index.
      LOOP AT ITDATOS.
      indice = sy-index.
    * Nombre, grupo de personal y área de personal.
        LOOP AT P0001 WHERE PERNR EQ ITDATOS-PERNR.
    *      AND
    *                                   BEGDA LT FECHA-HIGH AND
    *                                   ENDDA GT FECHA-LOW.
    * Nos quedamos con el último resgistro que existe en la fecha seleccionada por pantalla.
          ITDATOS-ENAME = P0001-ENAME.
          ITDATOS-PERSG = P0001-PERSG.
          ITDATOS-PERSK = P0001-PERSK.
        ENDLOOP.
    * Dni.
        LOOP AT P0002 WHERE PERNR EQ ITDATOS-PERNR.
    *      AND
    *                                   BEGDA LT FECHA-HIGH AND
    *                                   ENDDA GT FECHA-LOW.
    * Nos quedamos con el último resgistro que existe en la fecha seleccionada por pantalla.
          ITDATOS-PERID = P0002-PERID(9).
        ENDLOOP.
        LOOP AT P0050 WHERE PERNR EQ ITDATOS-PERNR.
    *      AND
    *                                   BEGDA LT FECHA-HIGH AND
    *                                   ENDDA GT FECHA-LOW.
    * Nos quedamos con el último resgistro que existe en la fecha seleccionada por pantalla.
          ITDATOS-ZAUSW = P0050-ZAUSW.
        ENDLOOP.
    * Recogemos el dato de departamento del infotipo 0001
        SELECT SINGLE ORGEH FROM PA0001 INTO UNIDAD WHERE PERNR EQ ITDATOS-PERNR.
        SELECT SINGLE STEXT FROM HRP1000 INTO TEXTO WHERE OBJID EQ UNIDAD AND
                                                          PLVAR EQ '01'   AND
                                                          LANGU EQ 'S'.
        ITDATOS-DEPART = TEXTO.
    * Insertamos datos modificando tabla ITDATOS ya existente con la información específica.
        MODIFY ITDATOS index indice.
      ENDLOOP.
    ENDFORM.                    " RELLENA_DATOS_GENERALES
    Thanks a lot,
    Regards,
    Rebeca

    Hi,
    Take another internal table and work area same as the initial internal table and work area used in screen 8002 which is to be used to delete the selected data.
    Take the names of the input/output fields as work_area-field_name and select column in table control as work_area-flag.
    Also take a flag field of size 1 datatype character as the last field in the internal table and work area while declaration.
    You have to pass a code in PBO of the screen for reading internal table into the table control.
    So it reads the internal table into the table control whenever you perform any action on use command.
    All you need to do is to write a code to modify the internal table form the table control while performing any user action.
    At screen logic,
    PROCESS BEFORE OUTPUT.
      MODULE status_8002. "for pf-status
      LOOP WITH CONTROL po_tab. "po_tab is table control
        MODULE pass_data. "to pass data into table control from internal table
      ENDLOOP.
    PROCESS AFTER INPUT.
      MODULE user_command_8002. "for user command(back and exit)
      LOOP WITH CONTROL po_tab.
        MODULE modify_data. "to modify data from table control into table control
      ENDLOOP.
    In PBO,
    *&      Module  STATUS_8002 OUTPUT
    MODULE status_8002 OUTPUT.
      SET pf-status 'ZAB_PFSTA'. " pf-status
      DATA : line_count TYPE i.
      DESCIRBE TABLE it_ekpo
      LINES line_count.
      po_tab-lines = line_count + 10.
      " to make table control scrollable
    ENDMODULE.                 " STATUS_8002  OUTPUT
    *&      Module  PASS_DATA  OUTPUT
    MODULE pass_data OUTPUT.
      READ TABLE it_ekpo into wa_ekpo INDEX po_tab-current_line.
    ENDMODULE.                 " PASS_DATA  OUTPUT
    "it_ekpo is internal table and wa_ekpo is the work area
    In PAI,
    *&      Module  MODIFY_DATA  INPUT
    MODULE MODIFY_DATA INPUT.
      MODIFY IT_EKPO INDEX PO_TAB-CURRENT_LINE FROM WA_EKPO.
      "modify records from table control into the internal table
    ENDMODULE.                 " MODIFY_DATA  INPUT
    Now at PAI, if you done any changes in the table control, then all these changes will be reflected to the internal table, and PBO will read the modified internal table.
    Hope this solves your problem.
    Thanks & Regards,
    Tarun Gambhir

  • How to get multiple rows from database table?

    hello !
    I need to get multiple rows from a OLEDB database table and display them on a table object.
    I did "Wrap in subfrom" on the table,  set  subform of the table to "flowed", and checked "Repeat row for each data item" of Row1 of the table.
    But I can get only one row on the table object.
    I need your help.
    Thanks

    Hi,
    best practices when deleting multiple rows is to do this on the business service, not the view layer for performance reasons. When you selected the rows to delete and press submit, then in a managed bean you access thetable instance (put a reference to a managed bean from the table "binding" property") and call getSeletedRowKeys. In JDeveloper 11g, ADF Faces returns the RowKeySet as a Set of List, where each list conatins the server side row key (e.g. oracle.jbo.Key) if you use ADF BC. Then you create a List (ArrayList) with this keys in it and call a method exposed on the business service (through a method activity in ADF) and pass the list as an argument. On the server side you then access the View Object that holds the data and find the row to delte by the keys in the list
    Example 134 here: http://blogs.oracle.com/smuenchadf/examples/#134 provides you with the code
    Frank

  • How to delete a row from database table in facade client

    Hi all,
    I followed the tutorial in creating a persistence entity from database table, then a session facade. Then I followed the tutorial to create a sample client to test the model. In the session facade, I could use persistEntity method to insert a record to the database. I am just thinking of an extension to the tutorial, i.e., being able to delete the record too. So I created a new method removeEntity in the session facade
    public void removeEntity(Object entity) {
    entity=em.merge(entity);
    em.remove(entity);
    em.flush();
    and called it in the sample client. It was executed without any error, but the record in the table still exists.
    I tried to look around for a solution, but I did not find one. Would anybody here please help out? Many thanks in advance!

    Hi Frank,
    I tried the code snippet, but I got the following exception when executing this code:
    javax.ejb.EJBException: EJB Exception: ; nested exception is:
         java.lang.IllegalStateException: The method public abstract javax.persistence.EntityTransaction javax.persistence.EntityManager.getTransaction() cannot be invoked in the context of a JTA EntityManager.; nested exception is: java.lang.IllegalStateException: The method public abstract javax.persistence.EntityTransaction javax.persistence.EntityManager.getTransaction() cannot be invoked in the context of a JTA EntityManager.
    java.lang.IllegalStateException: The method public abstract javax.persistence.EntityTransaction javax.persistence.EntityManager.getTransaction() cannot be invoked in the context of a JTA EntityManager.
         at weblogic.deployment.BasePersistenceContextProxyImpl.validateInvocation(BasePersistenceContextProxyImpl.java:121)
         at weblogic.deployment.BasePersistenceContextProxyImpl.invoke(BasePersistenceContextProxyImpl.java:86)
         at weblogic.deployment.TransactionalEntityManagerProxyImpl.invoke(TransactionalEntityManagerProxyImpl.java:91)
         at weblogic.deployment.BasePersistenceContextProxyImpl.invoke(BasePersistenceContextProxyImpl.java:80)
         at weblogic.deployment.TransactionalEntityManagerProxyImpl.invoke(TransactionalEntityManagerProxyImpl.java:26)
         at $Proxy141.getTransaction(Unknown Source)
         at model.SessionEJBBean.removeEntity(SessionEJBBean.java:60)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.jee.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:37)
         at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:55)
         at com.bea.core.repackaged.springframework.jee.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:50)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
         at $Proxy143.removeEntity(Unknown Source)
         at model.SessionEJB_qxt9um_SessionEJBImpl.removeEntity(SessionEJB_qxt9um_SessionEJBImpl.java:142)
         at model.SessionEJB_qxt9um_SessionEJBImpl_WLSkel.invoke(Unknown Source)
         at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:589)
         at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:230)
         at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:477)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:147)
         at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:473)
         at weblogic.rmi.internal.wls.WLSExecuteRequest.run(WLSExecuteRequest.java:118)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    javax.ejb.EJBException: EJB Exception: ; nested exception is:
         java.lang.IllegalStateException: The method public abstract javax.persistence.EntityTransaction javax.persistence.EntityManager.getTransaction() cannot be invoked in the context of a JTA EntityManager.; nested exception is: java.lang.IllegalStateException: The method public abstract javax.persistence.EntityTransaction javax.persistence.EntityManager.getTransaction() cannot be invoked in the context of a JTA EntityManager.
         at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.unwrapRemoteException(RemoteBusinessIntfProxy.java:109)
         at weblogic.ejb.container.internal.RemoteBusinessIntfProxy.invoke(RemoteBusinessIntfProxy.java:91)
         at $Proxy0.removeEntity(Unknown Source)
         at model.SessionEJBClient.main(SessionEJBClient.java:71)
    Caused by: java.lang.IllegalStateException: The method public abstract javax.persistence.EntityTransaction javax.persistence.EntityManager.getTransaction() cannot be invoked in the context of a JTA EntityManager.
         at weblogic.deployment.BasePersistenceContextProxyImpl.validateInvocation(BasePersistenceContextProxyImpl.java:121)
         at weblogic.deployment.BasePersistenceContextProxyImpl.invoke(BasePersistenceContextProxyImpl.java:86)
         at weblogic.deployment.TransactionalEntityManagerProxyImpl.invoke(TransactionalEntityManagerProxyImpl.java:91)
         at weblogic.deployment.BasePersistenceContextProxyImpl.invoke(BasePersistenceContextProxyImpl.java:80)
         at weblogic.deployment.TransactionalEntityManagerProxyImpl.invoke(TransactionalEntityManagerProxyImpl.java:26)
         at $Proxy141.getTransaction(Unknown Source)
         at model.SessionEJBBean.removeEntity(SessionEJBBean.java:60)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.jee.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:37)
         at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:55)
         at com.bea.core.repackaged.springframework.jee.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:50)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
         at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
         at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
         at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
         at $Proxy143.removeEntity(Unknown Source)
         at model.SessionEJB_qxt9um_SessionEJBImpl.removeEntity(SessionEJB_qxt9um_SessionEJBImpl.java:142)
         at model.SessionEJB_qxt9um_SessionEJBImpl_WLSkel.invoke(Unknown Source)
         at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:589)
         at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:230)
         at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:477)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:147)
         at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:473)
         at weblogic.rmi.internal.wls.WLSExecuteRequest.run(WLSExecuteRequest.java:118)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    Process exited with exit code 0.

  • How to get current row of Advanced table with no submit

    I have an advanced table with an 'Add another button'. When an empty row is created by clicking this button, LOV is used on the first column to populate other fields of the row. The rows of the table carry a button called "Add dependencies" whose functionality is to take the user to a different table to add rows to a different VO. This button is just a button and not a submitButton. I am passing the row's primary key as part of the URI as Vo attribute FdTaskId={@FdTaskId}
    The button works perfectly fine for database fetched rows (rows already present in the database), but, for the rows created using 'Add Another button', though LOV populates all fields including the primary key, the URI parameter passes null to the next page. That means, the VO attribute is not set. This works fine only when a 'submit' happens in the first page. For example, if I click Add another row again, then the previously inserted row passes the primary key fine as part of {@FdTaskId}.
    Could you please help me how I can resolve this issue?
    Thanks,
    Datta

    I am doing exactly that. My issues is that, VO attribute is passed correct for the table rows which are fetched from the database. For the table rows which got created through 'Add Another button', the VO attribute passed through URI as {@FdTaskId} is returning null. The VO attribute sets only when a form submit happens. For example, after adding a row through 'Add another row' button, click the same button again to add one more row and now go back to previously added row and now you can see that its VO attribute is set ({@FdTaskId} carries value )

  • How to check the number of rows in a table with input data?`

    Dear all,
    I am having a table ( with declaration of 5 rows during the init ) there's a next button which will add another 5 rows by pressing. Let say the user ony key in 7 rows of data.. how should i track it? coz these data act as input to my bapi function. One of the input field of my bapi is to state how many rows of data that a user had key in. Thank you.

    I think ur problem is empty records, u dont want to process empty table rows.
    m I right?
    if yes then just before processing the data / records, check for empty records and remove unwanted rows from the node.
    for (int i = 0; i < TableNode.size(); i++)
             if all cells of row(i) are empty
                   remove row(i) from Table Node.
    OR if you dont want to remove empty rows from display (screen), then at the time of processing, transfer useful rows to a separate node and process that node.
    Best Regards
    Deepak

  • How to select one row in a table with radio button

    Hi all.
    I have a VO where there is an attribute (isDefault [String]) that identifies the default record in the view. The possible values are 'Y' for yes and 'N' for no. Obviously only one record can have the 'Y' value.
    In my page I have created an ADF Table (with the usual data control drag & drop). I would to transform the default inputText of "isDefault" field with a selectOneRadio component in order to permit the user to select (and save contextually in the DB) the default row of this table.
    Can you explain me how? I'm using JDeveloper 11.1.1.4.
    Thanks in advance.
    Baduel

    Baduel wrote:
    Cvele,
    thanks for your responses. Yes, it's easier to use af:selectBooleanCheckbox but I need that the selection is mutually exclusive (only one row can be selected). >If this is possible also with the boolean checkbox please tell me how.- Let's try with CheckBox :
    1. At the ViewObjectImpl level (for example, YourViewObjectImpl), add the following code:
      private oracle.jbo.Key currSelectedRowKey = null;
      public void doRowSelection(Key newKey) {
          // de-select old one
          if (currSelectedRowKey != null) {
              Row[] rows = findByKey(currSelectedRowKey,  1);
              if (rows != null && rows.length > 0)
                   rows[0].setStatusAsBoolean(Boolean.FALSE); // cast to the appropriate row Impl class if need !
         // remember a new selected row key:
        currSelectedRowKey = newKey;
      }In the ViewRowImpl, in the transient attr settter, do as follows:
      public void setStatusAsBoolean(Boolean value) {
         setStatus(value.booleanValue() ? ONE : ZERO);
         if (value.booleanValue()) {
             YourViewObjectImpl vo = (YourViewObjectImpl)getViewObject();
             vo.doRowSelection(getKey());
       }   P.S. The above was not tested at all, but should give you an idea

  • How to remove a row from a jtable with DefaultTableModel

    Hi to all,]
    I want to remove a row from jtable. I am using DefaultTableModel.
    I have got some example but every example is given with AbstractTableModel
    Please help me...
    Thanks and Regards

    I want to remove a row from jtable. I am using DefaultTableModel.How do you program without reading the API.
    The name of the method you use is "removeRow". How hard is that to find by reading the API?
    Not only do you not bother to read the API, you don't even bother to read and respond to your old postings when you get help:
    http://forum.java.sun.com/thread.jspa?threadID=5137773
    http://forum.java.sun.com/thread.jspa?threadID=5134667
    http://forum.java.sun.com/thread.jspa?threadID=5131162
    Your on your own in the future.

  • How to append new rows in a table with Javascript ?

    Hi ,
    I'd like to append new rows in a table dynamically using javascript?
    Do some of you have already done this before ?

    Rui's answer will create copies of the entire table.  There may be times where thsi is what you want, but you asked about creating new rows.  If your new row is a copy of one of your existing rows, then you could use
    _RowName.addInstance(1);
    (the underscore at the beginning invokes the instance manager).  Is this what you're looking for?

  • How to select and field from an table with similar value

    Hi Gurus,
          I got an requirement where i need to capture some values from an table whose value start with "vmr*"
    could anyone tell me the syntax to be used with this?
    My table contains valies like "lrt", "vmr'" nut i need only  values starting with "vmr"*
    Ravi

    Hi,
    In where clause, you can write,
    where field  like 'vmr%'.
    Hope this helps.
    Reward if helpful.
    Regards,
    Sipra

  • How to compare input sound (from mic.) with sound on my database

    i want to campare sound (from mic.) with sound on my database
    ex:
    if i say "hello" it show message "hello"
    but if i say other word it will show message "try again"
    forgive for my english
    eak_

    Speech recognition is a whole area in its own right
    Lots of info and other references and the Java Speech APIs can be found here
    http://java.sun.com/products/java-media/speech/index.jsp

Maybe you are looking for