• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

Laravel SQL query midnight time not showing

phplaraveleloquentphp-carbon


PHP Snippet 1:

DB::table('ferries')->groupBy('ferry_name')
->whereTime('departure_time', '>', Carbon::now()->toTimeString())
->whereIn('schedule_type', ['Weekday'])
->where('terminal_name',$terminal_name)->orderBy('departure_time')->get()->all()

PHP Snippet 2:

$posts =  DB::table('ferries')->orderBy('departure_time', 'asc')
            ->where('departure_time', '>', Carbon::now()->toTimeString())
            ->whereIn('schedule_type', ['Weekday'])
            ->where('terminal_name', $terminal_name)->get()->unique('ferry_name')->all();

Related Snippets

Undefined Array Key error when uploading image on php

how to pass row id in href of a tag in codeigniter controller?

Symfony - EasyAdmin - Add and remove functions are ignored from AssociationField

Laravel websockets AWS EC2 - Connection failed

Laravel 5.1 Unknown database type enum requested

codeigniter 4 running error first time with xampp

Remove categories with all childs derived from parent category

Laravel Pagination links() not working

WooCommerce Subscriptions: Remove role on cancelled subscription

How to keep value of selected value after form submission?

Xdebug in Laravel is not working with VSCode

Issue saving card for customer

Sync Records With Default Values in Pivot Tables, Call to undefined method syncWithPivotDefaults()

Performance of foreach, array_map with lambda and array_map with static function

How can I access an array/object?

About Contact Privacy policy Terms and conditions