PHPackages                             milesasylum/schnoop - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. milesasylum/schnoop

ActiveLibrary[Database &amp; ORM](/categories/database)

milesasylum/schnoop
===================

Schnoop provides a convenient PHP interface for inspecting a database schema.

v0.4.2(1y ago)0165.8k↓14.6%1MITPHPPHP 7.2 - 8.3CI failing

Since Jul 21Pushed 1y ago1 watchersCompare

[ Source](https://github.com/courtney-miles/schnoop)[ Packagist](https://packagist.org/packages/milesasylum/schnoop)[ Docs](https://github.com/courtney-miles/schnoop)[ RSS](/packages/milesasylum-schnoop/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (10)Dependencies (4)Versions (17)Used By (0)

Schnoop: PHP Database Schema Inspector
======================================

[](#schnoop-php-database-schema-inspector)

[![Tests](https://github.com/courtney-miles/schnoop/actions/workflows/tests.yml/badge.svg)](https://github.com/courtney-miles/schnoop/actions/workflows/tests.yml) [![Coverage Status](https://camo.githubusercontent.com/4ecaf9938281360196ee10236fbb06362dd6ba2d66ac488a4840fb708f60dd3c/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f636f7572746e65792d6d696c65732f7363686e6f6f702f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/courtney-miles/schnoop?branch=master) [![Latest Stable Version](https://camo.githubusercontent.com/5dceeae3eed646806e5d580032119d75cbb527339f0f2a10ebf9f1c18a9010a1/68747470733a2f2f706f7365722e707567782e6f72672f6d696c65736173796c756d2f7363686e6f6f702f762f737461626c65)](https://packagist.org/packages/milesasylum/schnoop) [![Total Downloads](https://camo.githubusercontent.com/e19a7bade52d82c9b9929ca1e79e9f72d14a0bb41fb8142b26124e4d5a955653/68747470733a2f2f706f7365722e707567782e6f72672f6d696c65736173796c756d2f7363686e6f6f702f646f776e6c6f616473)](https://packagist.org/packages/milesasylum/schnoop) [![License](https://camo.githubusercontent.com/0f7a02f0b7bbec740ff0813ac233db0606168299b7fc210b5a7cc56bb0fd6d0f/68747470733a2f2f706f7365722e707567782e6f72672f6d696c65736173796c756d2f7363686e6f6f702f6c6963656e7365)](https://packagist.org/packages/milesasylum/schnoop)

Schnoop provides a convenient PHP interface for inspecting a MySQL database schema and producing the DDL statements for the schema.

It is intended to assist with code generation in development environments.

> **Disclaimer:** It is not advisable to use this package in production environments.

Examples
--------

[](#examples)

### Construct the Schnoop object

[](#construct-the-schnoop-object)

To construct the Schnoop object, first establish a PDO connection to your database server, then supply the connection to `SchnoopFactory::create()`.

```
