{"id":20797,"date":"2021-02-27T19:26:13","date_gmt":"2021-02-28T00:26:13","guid":{"rendered":"http:\/\/bangla.salearningschool.com\/recent-posts\/db-operations-for-laravel-a-mvc-based-php-framework-the-model-is-also-discussed\/"},"modified":"2021-04-06T18:28:38","modified_gmt":"2021-04-06T22:28:38","slug":"db-operations-for-laravel-a-mvc-based-php-framework-the-model-is-also-discussed","status":"publish","type":"post","link":"http:\/\/bangla.sitestree.com\/?p=20797","title":{"rendered":"DB Operations for Laravel (a MVC based PHP framework). The Model is also discussed"},"content":{"rendered":"<p>Different methods of DB operations are discussed.<br \/>\nHow to model using the Eloquent ORM is also discussed.<br \/>\nDB operations are shown in Plain SQL, or Using the Query builder, and also using the Model.<br \/>\nIn a later document, I will show the details of Laravel configurations and some MVC coding stuff.<br \/>\nYou do not need 100 years of experience to be able to use Laravel. If you have experience with similar stuff (one or more) such as CodeIgniter, Symfony, Zend, and\/or CakePHP (also in general you are good in programming, and also good in PHP, Database Design and Implementation, DB Modeling, ORM in other languages\/frameworks), you will be good to go in matter of days [even if you never heard of Laravel]<\/p>\n<p> From: http:\/\/sitestree.com\/?p=570<br \/> Categories:Web Development, Root, By Sayed Ahmed<br \/>Tags:<br \/> Post Data:2013-11-26 02:10:23<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Different methods of DB operations are discussed. How to model using the Eloquent ORM is also discussed. DB operations are shown in Plain SQL, or Using the Query builder, and also using the Model. In a later document, I will show the details of Laravel configurations and some MVC coding stuff. You do not need &hellip; <\/p>\n<p><a class=\"more-link btn\" href=\"http:\/\/bangla.sitestree.com\/?p=20797\">Continue reading<\/a><\/p>\n","protected":false},"author":8,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[1917,1852],"tags":[],"class_list":["post-20797","post","type-post","status-publish","format-standard","hentry","category-fromsitestree-com","category-laravel","item-wrap"],"jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":72724,"url":"http:\/\/bangla.sitestree.com\/?p=72724","url_meta":{"origin":20797,"position":0},"title":"Laravel News. Misc. Laravel","author":"Sayed","date":"February 7, 2022","format":false,"excerpt":"Scout APM: Intuitive Laravel Performance Monitoring Read More \u2192 Laravel 8.82 Released Read More \u2192 Tailwind CSS Laravel Package Read More \u2192 PHP Monitor 5.0 for macOS is Here Read More \u2192 Complete Web Scraping toolkit for PHP Read More \u2192 Migrator is a GUI Migration Manager for Laravel Our\u2026","rel":"","context":"In &quot;Jobs in Canada and USA&quot;","block_context":{"text":"Jobs in Canada and USA","link":"http:\/\/bangla.sitestree.com\/?cat=1953"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":24062,"url":"http:\/\/bangla.sitestree.com\/?p=24062","url_meta":{"origin":20797,"position":1},"title":"#LARAVEL. Misc Laravel News and Tutorials: PHP&#8217;s Git Server Compromised, Laravel Lambo, HasManyThrough Relations hips, and more &#8211; \u2116353","author":"Author-Check- Article-or-Video","date":"April 4, 2021","format":false,"excerpt":"PHP's Git Server Compromised HasManyThrough Relationships With Unlimited Levels Manage PHP and Valet from the macOS Status Bar Lambo CLI for Quick Application Creation With Laravel and Valet Major Heroicons Release Includes Vue\/React Components and Figma Files Soap - A Laravel SOAP client that provides a clean interface for handling\u2026","rel":"","context":"In &quot;Laravel&quot;","block_context":{"text":"Laravel","link":"http:\/\/bangla.sitestree.com\/?cat=1852"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":75821,"url":"http:\/\/bangla.sitestree.com\/?p=75821","url_meta":{"origin":20797,"position":2},"title":"Livewire v3, Laravel Tailwind Merge, Cross-Origin Resource Sharing, and more! &#8211; \u2116467","author":"Sayed","date":"June 25, 2023","format":false,"excerpt":"Your Laravel week in review \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f \u034f\u2026","rel":"","context":"In &quot;\u09ac\u09cd\u09b2\u0997 \u0964 Blog&quot;","block_context":{"text":"\u09ac\u09cd\u09b2\u0997 \u0964 Blog","link":"http:\/\/bangla.sitestree.com\/?cat=182"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/laravelnews.cmail19.com\/t\/d-o-vqluhl-xtyydulih\/o.gif?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":65754,"url":"http:\/\/bangla.sitestree.com\/?p=65754","url_meta":{"origin":20797,"position":3},"title":"Laravel Query Builder, Cheatsheet #Laravel","author":"Author-Check- Article-or-Video","date":"July 13, 2021","format":false,"excerpt":"$users = DB::table('users')->get() $user = DB::table('users')->where('name', 'John')->first(); $name = DB::table('users')->where('name', 'John')->pluck('name'); $roles = DB::table('roles')->lists('title'); $roles = DB::table('roles')->lists('title', 'name'); $users = DB::table('users')->select('name', 'email')->get(); $users = DB::table('users')->distinct()->get(); $users = DB::table('users')->select('name as user_name')->get(); $query = DB::table('users')->select('name'); $users = $query->addSelect('age')->get(); $users = DB::table('users')->where('votes', '>', 100)->get(); $users = DB::table('users')->where('votes', '>', 100)->orWhere('name', 'John')->get(); $users = DB::table('users')->whereBetween('votes',\u2026","rel":"","context":"In &quot;FromSitesTree.com&quot;","block_context":{"text":"FromSitesTree.com","link":"http:\/\/bangla.sitestree.com\/?cat=1917"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":23296,"url":"http:\/\/bangla.sitestree.com\/?p=23296","url_meta":{"origin":20797,"position":4},"title":"#laravel laracast intermediate Route Model Binding BDD and Conversations Stubs Elixir Versioning Passing Data to Views","author":"Author-Check- Article-or-Video","date":"March 28, 2021","format":false,"excerpt":"Route Model BindingLaravel 5 Fundamentals - Episode #18 LARAVEL \u2022 FEB 2ND, 2015 \u2022 INTERMEDIATE \u2022 7:02 ADD TO WATCHLIST MocksTesting Jargon - Episode #2 TESTING \u2022 DEC 12TH, 2014 \u2022 INTERMEDIATE \u2022 9:16 ADD TO WATCHLIST Acceptance Testing and User StoriesTesting Jargon - Episode #8 TESTING \u2022 DEC 31ST,\u2026","rel":"","context":"In &quot;Laravel&quot;","block_context":{"text":"Laravel","link":"http:\/\/bangla.sitestree.com\/?cat=1852"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":23295,"url":"http:\/\/bangla.sitestree.com\/?p=23295","url_meta":{"origin":20797,"position":5},"title":"#laravel One Level of Indentation laracast intermediate Install Laravel 5 Interfaces The Template Method Pattern","author":"Author-Check- Article-or-Video","date":"March 28, 2021","format":false,"excerpt":"One Level of IndentationSimple Rules for Simpler Code - Episode #3 PHP \u2022 NOV 13TH, 2014 \u2022 INTERMEDIATE \u2022 12:05 ADD TO WATCHLIST Install Laravel 5Laravel 5 Alpha From Scratch - Episode #2 LARAVEL \u2022 SEP 22ND, 2014 \u2022 INTERMEDIATE \u2022 4:29 ADD TO WATCHLIST Don't Use \"Else\"Simple Rules for\u2026","rel":"","context":"In &quot;Laravel&quot;","block_context":{"text":"Laravel","link":"http:\/\/bangla.sitestree.com\/?cat=1852"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_featured_media_url":"","_links":{"self":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/20797","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/users\/8"}],"replies":[{"embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=20797"}],"version-history":[{"count":1,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/20797\/revisions"}],"predecessor-version":[{"id":23359,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=\/wp\/v2\/posts\/20797\/revisions\/23359"}],"wp:attachment":[{"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=20797"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=20797"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/bangla.sitestree.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=20797"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}