You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Comunidad de Visual Foxpro en Español
Cuando quiero salir me da el mensaje de error de sesiones abiertas.
Como se me generan y como las cierro.
Podría alguien ayudarme esto con mariadb y foxydb.
Antonio Meza
unread,
Oct 10, 2017, 7:43:03 PM10/10/17
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Comunidad de Visual Foxpro en Español
Cuando mandas a guardar con odb.Update() se genera una transacción en el servidor de MariaDB si algo sale mal por ejemplo al usar odb.Commit() debes mandar un odb.Rollback() para deshacer la transacción.
If odb.Commit()
* Todo perfecto
else
* Algo salio mal
odb.RollBack()
endif
prueba y comentas
saludos
Antonio Meza
Alessio Pesce
unread,
May 24, 2019, 12:34:03 PM5/24/19
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Comunidad de Visual Foxpro en Español
entonces no sirve hacer asì
lOkTransaction = odb.update('tablas') && ESTE CONTROL NO ES EMPORTANTE?
IF (lOkTransaction)
ODB.COMMIT()
ELSE
ODB.ROLLBACK()
ENDIF
Antonio Meza
unread,
May 25, 2019, 1:21:52 PM5/25/19
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Comunidad de Visual Foxpro en Español
Ambos son importantes, es decir seria algo así
if odb.update('tabla') if odb.Commit() wait windows "Listo" else odb.Rollback() wait windows "Error" endif else odb.Rollback() wait windows "Error"
endif
Pero si tienes varias tablas primero tienes que saber si todos los .Update() fueron correctos para enviar el .Commit() y validar que este se ejecute también correctamente y si alguno marco error entonces el RollBack()
saludos
Antonio Meza
Alessio Pesce
unread,
May 25, 2019, 5:22:49 PM5/25/19
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message