Last active
June 12, 2018 08:52
-
-
Save kayintveen/2c0ba9b1475928e925d260acff8fa988 to your computer and use it in GitHub Desktop.
Magento2 log all sql queries
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// in app/etc/di.xml | |
// change the following lines | |
<preference for="Magento\Framework\DB\LoggerInterface" type="Magento\Framework\DB\Logger\LoggerProxy"/> | |
// for the following: | |
<type name="Magento\Framework\DB\Logger\File"> | |
<arguments> | |
<argument name="logAllQueries" xsi:type="boolean">true</argument> | |
<argument name="debugFile" xsi:type="string">log/sql.log</argument> | |
</arguments> | |
</type> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment