Skip to content
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

Doesn't support PostgreSql #7

Open
icsarisakal opened this issue Oct 3, 2024 · 7 comments
Open

Doesn't support PostgreSql #7

icsarisakal opened this issue Oct 3, 2024 · 7 comments
Labels
bug Something isn't working Fund

Comments

@icsarisakal
Copy link

icsarisakal commented Oct 3, 2024

When I try install this package, composer install all tomatophp extension too. Then, try to exec filament-invoices:install command, and errored about sqlstate. You prepared as sql file not migration.

The Error:

$ php artisan filament-invoices:install
Publish Vendor Assets

   Illuminate\Database\QueryException 

  SQLSTATE[42P01]: Undefined table: 7 ERROR:  relation "types" does not exist
LINE 1: select * from "types" where "for" = $1 and "type" = $2 and "...
                      ^ (Connection: pgsql, SQL: select * from "types" where "for" = invoices and "type" = status and "key" = draft limit 1)

  at vendor/laravel/framework/src/Illuminate/Database/Connection.php:825
    821▕                     $this->getName(), $query, $this->prepareBindings($bindings), $e
    822▕                 );
    823▕             }
    824▕
  ➜ 825▕             throw new QueryException(
    826▕                 $this->getName(), $query, $this->prepareBindings($bindings), $e
    827▕             );
    828▕         }
    829▕     }

      +40 vendor frames 

  41  artisan:13
      Illuminate\Foundation\Application::handleCommand()

Upvote & Fund

  • We're using Polar.sh so you can upvote and help fund this issue.
  • We receive the funding once the issue is completed & confirmed by you.
  • Thank you in advance for helping prioritize & fund our backlog.
Fund with Polar
Copy link

linear bot commented Oct 3, 2024

@3x1io
Copy link
Member

3x1io commented Oct 9, 2024

Hi @icsarisakal, could you provide more details about this error? I believe it should be working fine. We haven't tested it on Postgres, but it only uses ORM, so it should work.

@3x1io 3x1io added the bug Something isn't working label Oct 9, 2024
@icsarisakal
Copy link
Author

icsarisakal commented Oct 9, 2024

Of course, I try to install invoices via your instructions. I exec composer require tomatophp/filament-invoices then it's ok. After that, I try to exec php artisan filament-invoices:install then its errored about sql which I mentioned previous comment and additionally, it's errored as

php artisan migrate

  INFO  Running migrations.  

 2021_04_14_182305_fill_all_vars ...................................................................................................... 6.64ms FAIL

  PDOException 

 SQLSTATE[42601]: Syntax error: 7 ERROR:  syntax error at or near "`"
LINE 2: INSERT INTO `countries` (`id`, `name`, `code`, `phone`, `cre...

I think is about generated mysql sql in vendor/tomatophp/filament-invoices/database/migrations and vendor/tomatophp/filament-locations/database/data/countries.sql. This countries sql file is formatted as MySQL syntax. If you control db engine we can pass the error section. Thanks.

@3x1io
Copy link
Member

3x1io commented Oct 9, 2024

@icsarisakal yes i know about this problem it's because of Location plugin and I will fix it very soon, thanks for your report

@icsarisakal
Copy link
Author

@icsarisakal yes i know about this problem it's because of Location plugin and I will fix it very soon, thanks for your report

thanks a lot

@icsarisakal
Copy link
Author

@3x1io i can help if you want

@3x1io
Copy link
Member

3x1io commented Oct 9, 2024

yes please @icsarisakal it will be great

@polar-sh polar-sh bot added the Fund label Oct 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Fund
Projects
None yet
Development

No branches or pull requests

2 participants