JPA - How can i add ON DELETE CASCADE constraint ?

I have a three tables.
1. A (name)
2. B (name)
and relationship(manytomany) table of A and B
3. C (a_name,b_name)
I am using 2 JPA entities@Entity
public class A {
     @id
     String name;
     @ManyToMany
     @JoinTable(name="C",
               joinColumns=@JoinColumn(name="a_name"),
               inverseJoinColumns=@JoinColumn(name="b_name"))
     private List<B> bs = new ArrayList<B>();
     //getter setter methos
}and@Entity
public class B {
     @id
     String name;
     @ManyToMany(mappedBy="bs")
     private List<A> as = new ArrayList<A>();
     //getter setter methos
}DDL of table C which is generated by JPA is something like thatCREATE TABLE C (
"a_name" VARCHAR,
"b_name" VARCHAR,
CONSTRAINT "c_a_name_fkey" FOREIGN KEY ("a_name")
REFERENCES a(name)
ON DELETE NO ACTION
ON UPDATE NO ACTION,
CONSTRAINT "c_b_name_fkey" FOREIGN KEY ("b_name")
REFERENCES b(name)
ON DELETE NO ACTION
ON UPDATE NO ACTION
)but i want to add constraint ON DELETE CASCADE* instead of ON DELETE NO ACTION_ in above relationship table C.
how can i do this ?
Thanks in advance.

Right click the message and select Edit as New.

Similar Messages

  • HT4759 How can I add or delete iphones from my icloud account?

    How can I add or delete iphones from my icloud account?

    Hi Inspiration69,
    I apologize, I'm a bit unclear on your question. If you are asking how to set up your iCloud account on your iPhone, you may find the following page helpful:
    Apple - iCloud - Setup
    https://www.apple.com/icloud/setup/ios.html
    Regards,
    - Brenden

  • How can i add and delete node in tree in run time

    i want to know the method that let me select tree node to delete it and another to input upon user inputs

    Hello,
    why don't you just enter "add tree node" in the Search Forum search box ?
    There are plenty of samples.
    Francois

  • I've searched to no avail for this problem. Similar posts but none that tell me what to do. I can't add or delete any bookmarks on my iPad 2 running the newest iOS. I know how it's suppose to work, it just isn't working!

    I've searched to no avail for this problem. Similar posts but none that tell me what to do. I can't add or delete any bookmarks on my iPad 2 running the newest iOS. I know how it's suppose to work, it just isn't working!
    It started after the major update to iOS 7.
    I can't believe that this is so hard to do. It's just not letting me. I can add a bookmark to the home screen just fine, just not in a bookmarks folder anywhere I try.
    I've used Apple products since 2001 and have always loved how intuitive they are. But the Safari browser since iOS 7 has been the worst I've experienced. At least right in the beginning after that update.
    I'd really appreciate any help that doesn't just tell me how it's suppose to work...I know that.
    My iPad 4 is not affected with the problem and works as it should.

    To delete, tap "Edit" (tap to enlarge image)

  • I have brought a iphone 4 and the person i brought it from has not deleted her icloud account i need her pasword to delete it but hse wont give it to me what can i do how can i add my icloud account can you give me a reasonable answer please. thank you

    i have brought a iphone 4 and the person i brought it from has not deleted her icloud account i need her pasword to delete it but hse wont give it to me what can i do how can i add my icloud account can you give me a reasonable answer please. thank you.

    The seller needs to follow this procedure:
    http://support.apple.com/kb/TS4515
    If she refuses, then as Tim suggested the iPhone is probably stolen. You'll need to contact your local police department and ask how to proceed.
    Regards.

  • When I try to print sth I can´t choose my printer. Adobe Reader only shows a printer I used years ago.I aleady deleted and reinstalled the Reader and deleted all other printers from the computer.How can I add a new printer to Adobe Reader?Thanks for help!

    When I try to print sth I can´t choose my printer. Adobe Reader only shows a printer I used years ago.I aleady deleted and reinstalled the Reader and deleted all other printers from the computer.How can I add a new printer to Adobe Reader?Thanks for help!

    Hi,
    I would suggest you to uninstall Adobe Reader using the cleaner tool and then re-install the latest version.
    Adobe Cleaner Tool:- Download Adobe Reader and Acrobat Cleaner Tool - Adobe Labs.
    Latest version of Adobe Reader:- http://get.adobe.com/reader/
    If you still experience the same issue, please share the following information:-
    - Screenshot of Adobe Reader showing printer options
    - Screenshot of Microsoft Word showing printer options
    - Screenshot of control panel- Control Panel\All Control Panel Items\Devices and Printers
    Regards,
    Nakul 

  • I have one playlist on iphone4. how can i add new playlist without deleting old one. i do not have old playlist in itunes any more.

    I have one playlist on iphone4. how can i add new playlist without deleting old one. i do not have old playlist in itunes any more.When i try to sync iphone with itunes it says that this action will remove my old playlist and all songs.

    "it says that this action will remove my old playlist and all songs."
    Are you connecting to a different iTunes library than you normally connect to?  That will erase the songs and playlists since the iPhone can't be connected to multiple libraries even if it is in manual sync mode.
    If you no longer have access to the original library that your iPhone calls 'home', then the only way to save the playlist (and the songs on your iPhone) would be to use a 3rd party application to extract your iPhone contents to this new iTunes library you're trying to connect to.

  • How can I add deleted tags again to my list of tags?

    Hi I've deleted my "red tag" from the list. How can I add it there again? thx a lot

    OK here is the answer: https://discussions.apple.com/message/23465520#23465520 Thx

  • HT1977 i want to add a app i just purchased to my i phone. nut when i click apply it asks me if i want to remove the rest of my apps.. which i dont.. how can i add the app without deleting my other apps

    i want to add a app i just purchased to my i phone. nut when i click apply it asks me if i want to remove the rest of my apps.. which i dont.. how can i add the app without deleting my other apps

    You can sync an iPhone to only one computer. If you connect it to a different computer (or you have never connected it to a computer) it will delete all iTunes content on the phone and replace it with the iTunes content on the current computer. As Avis says, you can transfer your purchases to the computer you are about to sync to, but only if that computer is authorized to the same account that the content was downloaded under.

  • HT1848 How can I add photos to the iPad while not deleting any currently on it? I have some photos from my brother's camera that I can't get again.  How could save them onto my iMac?

    I have uploaded photos from my brother's camera while on vacation to my iPad (1).  Now that I wish to add even more photos to the iPad,  iTunes say that it will replace all the photos once I sync again to add from an album on the iMac.
    WHOA.
    I'd like to upload the photos to the iMac! HOw can I do that?
    How can I add photos from albums on the iMac and not lose the ones I currently have stored onthe iPad.
    I cannot find this task addressed in any Help reference.
    I do not understand why I cannot make a simple file transfer back and forth.
    Many thanks!

    Another way. You can use a USB flash drive & the camera connection kit.
    Plug the USB flash drive into your computer & create a new folder titled DCIM. Then put your movie/photo files into the folder. The files must have a filename with exactly 8 characters long (no spaces) plus the file extension (i.e., my-movie.mov; DSCN0164.jpg).
    Now plug the flash drive into the iPad using the camera connection kit. Open the Photos app, the movie/photo files should appear & you can import. (You can not export using the camera connection kit.)
    Secrets of the iPad Camera Connection Kit
    http://howto.cnet.com/8301-11310_39-57401068-285/secrets-of-the-ipad-camera-conn ection-kit/
     Cheers, Tom

  • Deleted the recently added section from the source area how can i add back

    how can i add back the recently added section from the source without reinstalling itunes thanks in advance....
    insp 8100   Windows XP  

    Ok that is easy.
    1) File > New Smart Playlist.
    2) Make sure match the following rule is checked
    3)The first drop down change to date added.
    4)Set the second drop down setting
    5) Enter the number you want based on step 4
    The rest of the check marks are up to you but make sure "Live Updating" is checked.
    Take some time playing around with the smartlists. I love them!! I have a 2 level smartlist at work, I hardly use the regular playlists.

  • How can I add songs to my ipod without deleting what's on it?

    I have photos on my ipod that have been erased from my computer. How can I transfer them back to my computer or how can I *** music without deleting them?

    You will need that library copied from the old computer. If not, then you can take a look at this in getting 3rd party software to recover your library from the iPod. Syncing to a "New" Computer or replacing a "crashed" Hard Drive

  • I'm setting up Apple ids, and its not giving me the option to set up a rescue email. How can I add one?

    I'm setting up Apple IDs, and its not giving me the option to set up a rescue email. I've set up Apple ID's in the past, and its always given me the option. How can I add a rescue email?

    You can find the instructions here. I removed the screenshots but the text is copied below.
    http://support.apple.com/kb/HT5312?viewlocale=en_US&locale=en_US
    You can edit or delete your rescue email address at My Apple ID. To edit your rescue email address:
    Navigate to My Apple ID using your web browser.
    Click "Manage your account"
    When prompted, sign in using your Apple ID and password.
    Click Password & Security
    You'll be asked to answer 2 of your 3 security questions before you can make any modifications. If you are unable to remember your answers, you can choose to send an email to your rescue email to reset your security questions.
    Note: The option to send an email to reset your security questions and answers will not be available if a rescue email address is not provided. You will need to contact iTunes Store support in order to do so. 
    After you've validated your identity by correctly answering your security questions, click Edit to the right of your rescue email address.
    Once you've finished editing your rescue email address, click the Save button directly below the email field.  

  • HT4059 how can i add books to the library on my iphone 4s

    How can I add books to the library on my 4s?

    If the photos that you are wanting to delete are also in your Camera Roll then you can delete them from the camera roll

  • How can I add date to photos taken on my iphone 4s

    How can I add a date to photos taken on my iphone 4s?

    That's correct - Photos supports geotagging, but only allows viewing of that information. Once an image is in Photos, geotags cannot be added, deleted, or edited. This post suggests some apps for editing geotags outside of the Photos app. As you mentioned, you can edit the geotags in iPhoto, export to the finder and then import to Photos. I would guess (and hope!) we'll see this added in an update, and hopefully soon!

Maybe you are looking for

  • My ipod touch 5th gen has no sound through usb hookup-car

    I Have a kenwood ddx 370 touch screen HU installed in my car, and i can'y get sound from my speakers when its in ipod mode, and the wires are plugged in to the HU. I used to own a iphone 4, and a iphone 4s that both worked. now this issue is strange

  • IPod battier replacement program

    Other then Apple's do others have one that offer them installing instead of me? I know it will cost extra but I don't know how to do it and don't want it broken. Have a expert do it.

  • Dynamic report issue

    Dears, I'm back again I have and issue with my dynamic report: My source: DECLARE vTABLE VARCHAR2(100); vCOLUMN VARCHAR2(100); vVALUE varchar2(100); vSQL VARCHAR2(1000); BEGIN vTABLE := :P46_TABLELIST; vCOLUMN:=:P46_COLUMNLIST; vVALUE:=:P46_COLVALUE;

  • IMovie '11 terribly unstable, extremely slow, freezes

    I really hope someone here has some new piece of info that can solve my continuing iMovie problems.  I've used iMovie since version 4, been through the "HD" days and the transition from the old app to iMovie '08 and now '11.  I am running on a 2011 i

  • Regarding SRM ABAP

    Hi    I got a requirement to build logic in SAP SRM to capture purchase requisition that is ordered from ILA Catalog.Can you guide me on this.