skip to Main Content

Laravel: Getting 'SQLSTATE[HY000]: General error: 1 no such table: webServiceLogs' when trying to store in database – Phpmyadmin

I have set up a migration file: use IlluminateDatabaseMigrationsMigration; use IlluminateDatabaseSchemaBlueprint; use IlluminateSupportFacadesSchema; class LogggingTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::connection('mysql2')->create('webServiceLogs', function (Blueprint $table) { $table->bigIncrements('id'); $table->timestamps(); $table->string('query');…

VIEW QUESTION

Get daily data for Laravel 5.4 – Phpmyadmin

I want to get daily data from my database. I try 2 code and both are not working for me. $sales=Sale::whereDate('created_at', '=', Carbon::today()); The error that I got: Class 'AppHttpControllersCarbon' not found and when I try $sales=Sale::whereDay('created_at', now()->day)->get(); The error…

VIEW QUESTION
Back To Top
Search