Skip to content

Tag: laravel

How to use multiple whereBetween to sum two different record

I need to compare and sum data from two different date. Assuming i have 4 input dates Currently, my query only able to get one whereBetween date data as below Current Code Current result from startdate and enddate Example another result from compare_startdate and compare_enddate How to query another result fr…

Difference between two days laravel query

Are there any way to get difference of two days (today & created_at) using laravel query? I have tried as follows.but that didn’t work for me Thank you! Answer the problem in your code is that you are using standard where that take a column as the first parameter not an expression … you can us…

Laravel Passport callback route returns null

I am learning Laravel Passport and developing an OAuth2 server. After creating a client I made the following call to get the authorization code The call works as expected and I got the authorization code, however when redirecting to the callback route which is defined like so It didn’t work, the respons…