Skip to content
This repository has been archived by the owner. It is now read-only.
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
app
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

Benchmark Database views for Laravel Eloquent

This repository is used to benchmark how Laravel Eloquent handles a database view for a model compared to a normal table.

Read the blog post here: https://www.hmazter.com/2018/09/using-database-views-as-tables-for-laravel-eloquent/

Installation

  1. git clone
  2. composer install
  3. copy .env.example and edit .env
  4. php artisan migrate --seed

Usage

Run one of these artisan commands using the unix time command:

fetch-posts-from-table-model  Fetch posts from the table model
fetch-posts-from-table-query  Fetch posts from the table with a query
fetch-posts-from-view-model   Fetch posts from the view model
fetch-posts-from-view-query   Fetch posts from the view with a query

ex:

time php artisan fetch-posts-from-table-model

About

This repository is used to benchmark how Laravel Eloquent handles a database view for a model compared to a normal table.

Resources

Releases

No releases published

Packages

No packages published
You can’t perform that action at this time.