1 Reply Latest reply on Oct 23, 2008 2:00 AM by Prasanth Kumar Sahu

    Composite Primary Key In a single table

    Mallikarjun SG Newbie


      I have a multiple primary key columns in a single table. i want to use these composite primary keys for deletion of a record in a table. what is the way to code the same. I am using CMP Bean and version is EJB2.0

      Please help me out.

      Thank you,

        • 1. Re: Composite Primary Key In a single table
          Prasanth Kumar Sahu Newbie


          I have a table which is having composite primary key(id,name), Can anyone tell me how to provide composite primary key in ejb-jar.xml.

          For primary key we can give like this:--

          <?xml version="1.0" encoding="UTF-8"?>

          <!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise
          JavaBeans 2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">






          pls provide me solution for entering composite primary key.