11.08.2017 Views

codebright

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Eloquent Queries 308<br />

1 [<br />

2 {<br />

3 id: 3,<br />

4 title: "Leaving Through The Window",<br />

5 artist: "Something Corporate",<br />

6 genre: "Piano Rock",<br />

7 year: 2002<br />

8 },<br />

9 {<br />

10 id: 4,<br />

11 title: "North",<br />

12 artist: "Something Corporate",<br />

13 genre: "Piano Rock",<br />

14 year: 2002<br />

15 },<br />

16 {<br />

17 id: 5,<br />

18 title: "...Anywhere But Here",<br />

19 artist: "The Ataris",<br />

20 genre: "Punk Rock",<br />

21 year: 1997<br />

22 }<br />

23 ]<br />

WhereIn<br />

The whereIn() method can be used to check that a column value exists within a set of values. It’s<br />

really useful when you already have an array of possible values to hand. Let’s take a look at how it<br />

can be used.<br />

1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!