ASP.net
Awesome
Learn
Forum
Buy
Demos
Sign In
☾
☀
Switch to
Dark
Light
Mode
this site works best with javascript enabled
Ask Question
Master detail with Identity field, avoid saving to Db before saving master
Title:
B
I
{code}
?
I have two tables in the database, one master and the other details, both of which have an ID field Identity, and I do not want to save the information in the database when creating the details, and by pressing the save button on the master page, the master details will be saved at the same time. How do I do this?
Save Changes
Cancel
Arash
asked at 12 Oct 2020
Answers
B
I
{code}
?
When creating details for a new unsaved master, you need to save them somewhere in a temporary location, and when you save the master you'll transfer them from the temporary location to the permanent. That temporary location could be anything you want (client variable, Session, different Db table etc.)
Save Changes
Cancel
Omu
answered at 12 Oct 2020
Thanks for your guidance How do I do the same with ASP.net Core / MVC Awesome?
at 12 Oct 2020
Arash
regardless if you're using plain html inputs or awesome controls, the code will be the same, you need to save to a temp location, and on save transfer to permanent
at 13 Oct 2020
Omu
please
Sign In
to leave an answer
By accessing this site, you agree to store cookies on your device and disclose information in accordance with our
cookie policy
and
privacy policy
.
OK