Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

[Question] PHP

  • 05-01-2016 03:00PM
    #1
    Registered Users, Registered Users 2 Posts: 648 ✭✭✭


    Does anyone here understand this question? If so, would you care to give me the answer so I can begin to understand it?

    Many thanks

    ORwfMC9.png


Comments

  • Registered Users, Registered Users 2 Posts: 7,100 ✭✭✭Talisman


    The code fragment is attempting to perform a database transaction using a try/catch block.

    It's a simple pattern:
    try {
      begin()
      execute()
      commit()
    } catch (exception) {
      rollback()
    }
    

    In fairness it's not that difficult to use a search engine to find the answer.


  • Moderators, Society & Culture Moderators Posts: 17,642 Mod ✭✭✭✭Graham


    Talisman wrote: »
    In fairness it's not that difficult to use a search engine to find the answer.

    That depends on what time the homework has to be handed in.

    This might be useful OP: http://www.boards.ie/vbulletin/showpost.php?p=52731901&postcount=2


Advertisement