I have User into my application and each user has assigned (District,Tehsil,UC,Villages) these are cascade in nature means
1-District contains tehsils
2-Tehsil contains ucs
3-Ucs contains villages
Now i have place checkboxes and they are populating right based on selected , but when i de select or select another districts the previous checkbox result set lost due to post back.
My second question please suggest me a database structure for that
Loading

Vikram AgrawalPosted Jan 12, 2015, 6:02 AM
Maintain your table as @Jitendra explained, and in user table put villageId column.
and one more thing i want to suggest you as you are using server side codes for populating the values based on district so make this in client side then performance of your web page will be increase and also you will not get these problem which are coming due to post backs.
Thanks.
Jitendra KumarPosted Jan 12, 2015, 5:48 AM
First, one problem in database that is you maintain a primary foreign relationship in tables so why use district key again and again in the tables.
Tables likes :-
District (districtid,districtname)
Tehsil (district id(F), Tehsilid,tahsilname)
UC (TEhsilID(F),ucid,ucname)
Villages (UCID(F),Viallageid,village name)
And kindly share code for better understanding of problem.
Danish HabibPosted Jan 12, 2015, 5:36 AM
Jitendra KumarPosted Jan 12, 2015, 5:23 AM
Kindly share code file for better understanding problem.
First, if you select a district then how find tahsil uc village of user.
bcz acc to you district and tahsil have one to many relationship.