10.8 Expressions
The methods we have been using so far escape and quote the parameters you provide automatically,
but what if we need something really custom? What if we don’t want anything else added?
For this we can use the DB::raw() method. Here’s an example :
1 <?php
2
3 DB::table('shoes')->update(array('worn' => DB::raw('NOW()')));
In this query the NOW() will not be escaped or quoted. Lots of freedom there, but don’t forget
that spiderman quote! Be responsible with this power.
Anil Bist
Skills Laravel
Qualifications :- High School - SLV, College/University - Graphic Era Deemed Univ University,Location :-Dehradun,Dehradun,Uttarakhand,India
Description:-
I started my Professional Journey in 2006 with one of the Web Development Company in Bangalore and my 1st framework was "Ruby on Rail" as Web development and delivered around 5+ Projects using this platform. Then came another dimension as JEE/Sturst framework, Gradually I realized that I want to build something on my own and give my passion and energy on creating something different a
Explore