![]() |
Pete K 4/14/2022 |
Hi Rajesh, This is also a common scenario for me and the only way I've been able to manage is to insert a code snippet on the page and write code to display the data from the other table. You can of course add "fake" fields to the page by modifying the table query, but in that case you are faced with the add and edit pages attempting to modify the fake fields, which naturally throws an exception. I have long wished for a feature that would allow us to mark a field as "do not update" so the add/edit update pages display them but ignore them when doing the update. That would help in cases like this. Hope this helps. —Pete |
R
|
Rajesh author 4/14/2022 |
Hi Pete, Thank you for your response. I agree, that feature would help a lot. --Rajesh |
W
|
WilliamBDevClub member 5/15/2022 |
This is easy. I don't use code snippits for this as that requires another query. I add a dummy field as explained above. You just need to unset the value that you do not want added/updated. (As stated, they don't exist in the database.) On add page use Before added event and on an edit page use Before updated event. unset($values["Your_Field"]); Do this to every field you want to ignore. |
![]() |
jadachDevClub member 5/15/2022 |
unset will not work with aspr.net I have had success using var ctrl = Runner.getControl(pageid, 'Make'); I can auto-populate "fake" fields, display them and not submit them. |
![]() |
Sergey Kornilov admin 5/15/2022 |
Yes, it can be done.
select ...
|
R
|
Rajesh author 6/8/2022 |
Thank you everyone. -Rajesh |