You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Niamul Hasan edited this page Jan 3, 2021
·
1 revision
Reading Data from database
Here in this way we can actually run query on database, Generally we'll be using this method to read data from database.
If we want we can delete, insert and do others operation as well in this way. But there exists other methods for inserting and deleting data.
$data = DB::operation()->query('SELECT * from table');
print_r($data);
Here $data is our desired object.
For, printing data in HTML code we can simply run a for each loop.