Skip to content

sail artisan schema:dump... 'Unknown table 'COLUMN_STATISTICS' in information_schema' #251

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wemersonrv opened this issue Oct 6, 2021 · 3 comments

Comments

@wemersonrv
Copy link

  • Sail Version: ^1.0.1
  • Laravel Version: 8.62.0
  • PHP Version: 8.62.0
  • OS: macOS BigSur 11.5

Description:

When run sail artisan schema:dump gives me the following error:

% sail artisan schema:dump
mysqldump: [Warning] Using a password on the command line interface can be insecure.
mysqldump: Couldn't execute 'SELECT COLUMN_NAME,                       JSON_EXTRACT(HISTOGRAM, '$."number-of-buckets-specified"')                FROM information_schema.COLUMN_STATISTICS                WHERE SCHEMA_NAME = 'meuseventos' AND TABLE_NAME = 'events';': Unknown table 'COLUMN_STATISTICS' in information_schema (1109)

   Symfony\Component\Process\Exception\ProcessFailedException 

  The command "mysqldump  --user="${:LARAVEL_LOAD_USER}" --password="${:LARAVEL_LOAD_PASSWORD}" --host="${:LARAVEL_LOAD_HOST}" --port="${:LARAVEL_LOAD_PORT}" --skip-add-locks --skip-comments --skip-set-charset --tz-utc "${:LARAVEL_LOAD_DATABASE}" --routines --result-file="${:LARAVEL_LOAD_PATH}" --no-data" failed.

Exit Code: 2(Misuse of shell builtins)

Working directory: /var/www/html

Output:
================


Error Output:
================
mysqldump: [Warning] Using a password on the command line interface can be insecure.
mysqldump: Couldn't execute 'SELECT COLUMN_NAME,                       JSON_EXTRACT(HISTOGRAM, '$."number-of-buckets-specified"')                FROM information_schema.COLUMN_STATISTICS                WHERE SCHEMA_NAME = 'meuseventos' AND TABLE_NAME = 'events';': Unknown table 'COLUMN_STATISTICS' in information_schema (1109)

  at vendor/symfony/process/Process.php:270
    266▕      */
    267▕     public function mustRun(callable $callback = null, array $env = []): self
    268▕     {
    269▕         if (0 !== $this->run($callback, $env)) {
  ➜ 270▕             throw new ProcessFailedException($this);
    271▕         }
    272▕ 
    273▕         return $this;
    274▕     }

      +16 vendor frames 
  17  artisan:37
      Illuminate\Foundation\Console\Kernel::handle()

Steps To Reproduce:

  1. Clone the github repository and start sail
  2. run sail artisan schema:dump

My github repository: https://github.com/wemersonrv/sail-dump-issue

@saulens22
Copy link
Contributor

Try looking into this: spatie/laravel-backup#92

@driesvints
Copy link
Member

I can't reproduce this as I'm running into #250. I'll keep this open for now until we've solved #250

@driesvints
Copy link
Member

After the fix for #250 I didn't manage to reproduce this and dumping the schema went okay for me. This is probably something specific to your use case so I'd kindly ask you to try a support channel:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants