snipt

Ctrl+h for KB shortcuts

Text only

Transactions en Laravel 3

1
2
3
4
5
DB::transaction(function(){
    DB::query($sql_portada);
    DB::query($sql_404);
    DB::query($sql_generos);
});
https://snipt.net/embed/6a2db37f27fe3d4e036201e72b1a107e/
/raw/6a2db37f27fe3d4e036201e72b1a107e/
6a2db37f27fe3d4e036201e72b1a107e
text
Text only
5
2019-08-12T00:04:04
True
False
False
Dec 11, 2013 at 03:45 PM
/api/public/snipt/99902/
transactions-en-laravel-3
<table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><a href="#L-1">1</a> <a href="#L-2">2</a> <a href="#L-3">3</a> <a href="#L-4">4</a> <a href="#L-5">5</a></pre></div></td><td class="code"><div class="highlight"><pre><span></span><span id="L-1"><a name="L-1"></a>DB::transaction(function(){ </span><span id="L-2"><a name="L-2"></a> DB::query($sql_portada); </span><span id="L-3"><a name="L-3"></a> DB::query($sql_404); </span><span id="L-4"><a name="L-4"></a> DB::query($sql_generos); </span><span id="L-5"><a name="L-5"></a>}); </span></pre></div> </td></tr></table>
laravel, pdo, php