Download the PHP package simpl/sql without Composer
On this page you can find all versions of the php package simpl/sql. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Package sql
Short Description A dead-simple layer on top of PDO to make PDO setup and querying simpler
License MIT
Homepage https://github.com/simpl-php/sql
Informations about the package sql
Simple/SQL
A dead-simple layer on top of PDO to make PDO setup and querying simpler
This component makes it easy to make and execute SQL statements with PDO.
You can run parameterized queries in a single step instead of doing separate prepare and execute statements.
This will automatically convert your query to a prepared statement with parameterized queries to prevent nasty SQL injection attacks.
Installation
Usage
Connecting to the database.
Basic connection
Connection with configuration array.
Running a SELECT query with parameters.
Since this is just a wrapper around PDO, you'll get back a
\PDOStatement
object you can then operate on as you normally would.
See https://simpl-php.com/components/sql for full documentation.
Coding Standards
This library uses PHP_CodeSniffer to ensure coding standards are followed.
I have adopted the PHP FIG PSR-2 Coding Standard EXCEPT for the tabs vs spaces for indentation rule. PSR-2 says 4 spaces. I use tabs. No discussion.
To support indenting with tabs, I've defined a custom PSR-2 ruleset that extends the standard PSR-2 ruleset used by PHP_CodeSniffer. You can find this ruleset in the root of this project at PSR2Tabs.xml
Codesniffer
Codefixer
All versions of sql with dependencies
ext-pdo Version *