cakephp / cakephp/phinx

Ms Sql Server with Database case sensitive

Open
#1,341 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
PHP
Stars
4.5k
Forks
884
PR merge metrics
No merged PRs in 30d

Description

I have the need to run migrations using this tool on a MS SqlServer ( Microsoft Dynamics Nav) which is case sensitive.
I cannot do anything because I have the following error at the very beginning, even trying to get migration status:

Error: [PDOException] SQLSTATE[42S02]: [Microsoft][ODBC Driver 13 for SQL Server][SQL Server]Invalid object name 'information_schema.tables' ...
in [...] vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php on line 349

That table is in UPPERCASE on Database.

Is there any workaround ?

I am using cakephp Version 3.6.1
SqlServer 2016

Thank you
Rudy

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in vendor/robmorgan/phinx/src/Phinx/Db/Adapter/PdoAdapter.php around line 349 and reproduce the migration-status command against the reported case-sensitive SQL Server 2016 database. Trace the information_schema.tables lookup and verify the result with the same environment; done means migration status and migrations work for the reported database naming.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, sql
Domain
databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.