aspose file tools*
The moose likes JDBC and the fly likes Maintaining temporary database Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Maintaining temporary database" Watch "Maintaining temporary database" New topic
Author

Maintaining temporary database

vicky malhotra
Greenhorn

Joined: Feb 05, 2005
Posts: 16
Hi!

I have a application which does database administration. Here there is one table such that if the user updates it, he has to updtae a host of other tables else it will create inconsistency. So i need to carry all the data that is updated and finally after he is done, update the database. So how do i achieve that? there is the option where i keep all the data in an xmll and use xql and finally write to the database. But i am totally new to xml. So any suggestions on how to go abt it will be highly appreciated.

Regards,

Vivek
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
Assume host means parent.

Do you have keys there?
Why enabling one to update child record first?
Or you can disable the key, after insert enable that key again.
[ February 17, 2005: Message edited by: Adeel Ansari ]
vicky malhotra
Greenhorn

Joined: Feb 05, 2005
Posts: 16
Hi!

Let me explain further.
The thing is I have a master table say Country. Now I have 10 more tables that hold different information for that table, say divisions, departments. So when I add a country, ill need to add values in the dept and division n other such tables and link them to the country table via some mapping tables.
If i add the country only, without adding/updating all the other tables, my database will be inconsistent.

So how while the user updates all the tables, i actually need to keep all this updated values locally, then finally make a check that all the tables have been updated and only then do i actually update my database.

Regards,

Vivek
Adeel Ansari
Ranch Hand

Joined: Aug 15, 2004
Posts: 2874
I think it is a likely behavior Parent is there without any child. No problem at all.

I think you want a parent must have some childs otherwise cant be there as parent. right?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Maintaining temporary database