Actualizar valor de campo al guardar datos en otra tabla (Biblioteca)

Hola a todos, espero me puedan ayudar a resolver la siguiente duda.

Estoy creando una aplicación para tener mis libros ordenados. He creado las tablas: autor, libro, detalle, usuario
Suele ocurrir que a veces presto libros, y para no olvidarlo, quiero incluir ese detalle en la app, por ello en la tabla libro incluí un campo Estado que puede tener dos valores: Disponible o Prestado.

Al momento de prestar un libro, no logro encontrar la forma de actualizar el campo Estado de la tabla libro. Dicho sea de paso, la tabla detalle incorpora fechas de prestamo y devolución, y está referenciada a libro y
usuario.

Si me pueden ayudar con esto, les agradezco de antemano.

Solved Solved
0 2 169
1 ACCEPTED SOLUTION

Your data model is not exactly clear between the four tables. However it sounds that you wish to update Book status based on lending information in the Detail table.

In general, reference actions can help you update status of a column in one table based on some changes in another table. You may wish to take a look at the sample app for those actions.

https://www.appsheet.com/templates/This-app-shows-how-to-use-reference-actions?appGuidString=e76d2e7...

Please post back if you are looking for something else.

View solution in original post

2 REPLIES 2

Your data model is not exactly clear between the four tables. However it sounds that you wish to update Book status based on lending information in the Detail table.

In general, reference actions can help you update status of a column in one table based on some changes in another table. You may wish to take a look at the sample app for those actions.

https://www.appsheet.com/templates/This-app-shows-how-to-use-reference-actions?appGuidString=e76d2e7...

Please post back if you are looking for something else.

Thanks for your help!

Top Labels in this Space