StydeNet / enlighten

Enlighten your APIs with auto-generated documentation
MIT License
574 stars 32 forks source link

Unknown column 'order_num' into 'enlighten_example_groups' #39

Closed ianfortier closed 3 years ago

ianfortier commented 3 years ago

Describe the bug

SQLSTATE[42S22]: Column not found: 1054 Unknown column 'order_num' in 'field list' (SQL: insert intoenlighten_example_groups(title,description,area,slug,order_num,run_id,class_name,updated_at,created_at) values (xxxxxxxxxxxxxx, ?, unit, xxxxxxx, 9999, 1, Tests\Unit\XXXXXXX, 2020-11-15 19:21:51, 2020-11-15 19:21:51))

Additional context After upgrading from 0.3.6 to 0.5.2 I rerun the install and republish / fresh the migrations.

jeffochoa commented 3 years ago

Hi @ianfortier,

Please follow the instructions described on the changelog file to upgrade to the latest version https://github.com/StydeNet/enlighten/blob/main/CHANGELOG.md

It looks like you are using the old migrations file.

Try the following:

  1. Remove all the files in database/migrations/enlighten
  2. Publish the migrations files again with php artisan vendor:publish --tag=enlighten-migrations
  3. Run the migrations with php artisan enlighten:migrate:fresh

Run the tests again.

Cheers, Jeff.