Oh no! Where's the JavaScript?
Your Web browser does not have JavaScript enabled or does not support JavaScript. Please enable JavaScript on your Web browser to properly view this Web site, or upgrade to a Web browser that does support JavaScript.
Not a member yet? Click here to register.
Forgot Password?

How to use database-transactions?

Asked Modified Viewed 1,498 times
M
mawe4585
M
  • Member, joined since
  • Contributed 84 posts on the community forums.
  • Started 34 threads in the forums
  • Started this discussions
asked
Member

Hi ! :)

Does php-fusion support database transactions?
How would they work?
I need a transaction because i try to insert multiple records and so it happens it is possible that errors occur - after all i'm only human.
The problem then is that some records are there and others are not and the system would be inconsistent.
clean this mess up afterwards is a real pain.

I would like to know how to handle this.
Can someone give me some hints on this topic?

Thanks!
0 replies

2 posts

M
mawe4585
M
  • Member, joined since
  • Contributed 84 posts on the community forums.
  • Started 34 threads in the forums
  • Started this discussions
answered
Member

For now i use dbquery("begin"); since i'm using mysql without PDO, but i think there should be something more general that php-fusion deliveres like dbbegin(),dbcommit(),dbrollback()
0 replies
F
Falk
F
Falk 131
Need help?, Having trouble?
• View our Documentation for Guides, Standards and Functions
• Name and Organize your Topics and Content correctly in the corresponding Forums for best support results
• Attaching Log Files and Screenshots when reporting issues will help
• Provide with an URL to live example if one exists
• Please read the How to Report an Error post
• Please read and comply with the Code of Conduct

(¯·._.·(¯°·._.·°º*[ Project Manager ]*º°·._.·°¯)·._.·¯)
  • Super Admin, joined since
  • Contributed 6,201 posts on the community forums.
  • Started 639 threads in the forums
  • Answered 11 questions
answered
Super Admin

We have started such shortcuts with dynamics,
improvements such as
         dbquery_insert(DB_NEWS, $data, 'update');

and
            dbquery_insert(DB_NEWS, $data, 'save');

Documentation is not made for it yet but there are plenty of examples in the 10+ Infusions that exists in the 9 pack currently.
0 replies

Labels

None yet

Statistics

  • Views 0 views
  • Posts 2 posts
  • Votes 0 votes
  • Topic users 2 members

2 participants

F
F
Falk 131
Need help?, Having trouble?
• View our Documentation for Guides, Standards and Functions
• Name and Organize your Topics and Content correctly in the corresponding Forums for best support results
• Attaching Log Files and Screenshots when reporting issues will help
• Provide with an URL to live example if one exists
• Please read the How to Report an Error post
• Please read and comply with the Code of Conduct

(¯·._.·(¯°·._.·°º*[ Project Manager ]*º°·._.·°¯)·._.·¯)
  • Super Admin, joined since
  • Contributed 6,201 posts on the community forums.
  • Started 639 threads in the forums
  • Answered 11 questions
M
M
  • Member, joined since
  • Contributed 84 posts on the community forums.
  • Started 34 threads in the forums
  • Started this discussions

Notifications

Track thread

You are not receiving notifications from this thread.

Related Questions

Not yet