how to create transaction

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
qwerty199199
User
Posts: 30

how to create transaction

Post by qwerty199199 »

i have some about 3 query for updating the record based on the deleting trigger.... but sometimes it can cause error so i need to rollback all the transaction.... but how to create the transaction process?

i use "ew_Execute" to execute my update query
and "ew_ExecuteScalar" to get the value needed for update


mobhar
User
Posts: 11792

Post by mobhar »

It depends on the database engine and the ADOConnection class you are using. As we know, MySQL supports for MyISAM (does not support Rollback) and InnoDB engine (supports for Rollback).

In addition, if your web app is using MySQL, then it includes "ewmysql*.php" file that contains ADOConnection class with the auto rollback setting. You can customize the related setting from this file. Try generate by using other database, such as MS SQL Server, Oracle, MS Access, etc, then you will find which files should be customized regarding it.


qwerty199199
User
Posts: 30

Post by qwerty199199 »

i'm using mysql from xampp... every setting is standard...

maybe some simple example would be a very good help for a newbie like me :D

Thanks in advance


qwerty199199
User
Posts: 30

Post by qwerty199199 »

sorry... standard setting mean default setting from PHPmaker9

Not using "Use mysqli extension"
using "No Cache"
Uncheck Connection Method "URL"
username "root"
pass -> empty
Database Type "MySQL"
SQL Identifier "Default"
Port "3306"


Post Reply