Originally posted by Uma, Mula:
I am trying to compare two table data and if we happpen to delete a row in first table it has to delete in the second table also. And my program has to be bidirectional also. I mean it has to check from table 1 to 2 or 2 to 1 according to the requirement. Please tell me how to write a program for this application.
sounds like a database trigger would be more suitable here. If it is due to avoiding "orphaned" rows, you should have some sort of table relationships deal with this. Sounds like a lot of overhead to be maintaining the tables programmatically.
Also, no one is going to write the program for you(for free). Give it your best shot, then post the relevant code if you are having troubles. If you don't know where to begin, try Sun's JDBC tutorials: