doctrine/sql-formatter

Cannot render SQL queries containing binary strings

オープン

#91 opened on 2023/07/21

 (4 件のコメント) (3 件のリアクション) (0 人の担当者)HTML (17 件のフォーク)batch import
enhancementhelp wanted

Repository metrics

Stars
 (1,559 個のスター)
PR merge metrics
 (平均マージ 4h 20m) (30d で 1 merged PR)

説明

At the moment, even though valid, these kind of queries would crash doctrine-bundle + twig

$connection->executeQuery("SELECT {$connection->quote((new \Symfony\Component\Uid\Ulid())->toBinary())}");

We are running all of these queries through this formatter, so I think formatter should do something about these, eg. detect non-utf8 parts and replace them with something.

Original issue was https://github.com/doctrine/DoctrineBundle/issues/1315, I'm moving it here

コントリビューターガイド