Download the PHP package clearsoft/easysql-connectors without Composer

On this page you can find all versions of the php package clearsoft/easysql-connectors. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package easysql-connectors

clearsoft/easysql-connectors

Database connectors for the EasySQL PHP SDK — local schema introspection and SELECT execution for MySQL/MariaDB, PostgreSQL, SQLite, ClickHouse, SQL Server, Oracle, Firebird, Db2, DuckDB, libSQL, Cloudflare D1, Snowflake, BigQuery, Trino and SAP HANA.

Installation

Requirements: PHP >= 8.2 and ext-pdo. Each engine's driver is an optional extension (or, for BigQuery, an optional Composer package), declared under suggest and loaded only when that engine is used:

Engine Driver
MySQL/MariaDB ext-pdo_mysql
PostgreSQL ext-pdo_pgsql
SQLite ext-pdo_sqlite
ClickHouse ext-curl
SQL Server ext-pdo_sqlsrv
Oracle ext-pdo_oci
Firebird ext-pdo_firebird
Db2 ext-pdo_ibm
DuckDB ext-pdo_duckdb
libSQL (local file) ext-pdo_sqlite
libSQL (remote) ext-curl
Cloudflare D1 ext-curl
Snowflake ext-pdo_odbc
SAP HANA ext-pdo_odbc
Trino ext-curl
BigQuery google/cloud-bigquery

Usage

Every engine shares one lifecycle (connect/close/introspect/execute) and one entry point, ConnectorFactory:

An options array is accepted in place of a config object:

Or an engine-native URL/DSN string (parsed by clearsoft/easysql-common):

A MySQL/MariaDB connection can also go over a local Unix socket instead of TCP — common on shared hosting (e.g. DB_HOST=host:/path/mysql.sock, as honoured by wpdb). Set socket and it takes precedence over host/port:

Connection URLs express a TCP target only, so a Unix socket cannot be encoded in a mysql://… string: pass it through the socket option or the MySQL\ConnectionConfig constructor argument instead.

Engine classes stay available directly from their sub-namespace when the engine is already known:

Behavior

Engines

Engine id Config class Catalog
mysql, mariadb MySQL\ConnectionConfig information_schema
postgresql Postgres\ConnectionConfig pg_catalog
sqlite SQLite\ConnectionConfig sqlite_master + PRAGMA
clickhouse ClickHouse\ConnectionConfig system over HTTP
sqlserver SqlServer\ConnectionConfig sys.*
oracle Oracle\ConnectionConfig ALL_* dictionary views
firebird Firebird\ConnectionConfig RDB$ system tables
db2 Db2\ConnectionConfig SYSCAT
duckdb DuckDb\ConnectionConfig duckdb_tables()/duckdb_columns()
libsql LibSql\ConnectionConfig sqlite_master + PRAGMA
d1 D1\ConnectionConfig sqlite_master + PRAGMA over the D1 REST API
snowflake Snowflake\ConnectionConfig INFORMATION_SCHEMA
bigquery BigQuery\ConnectionConfig dataset/table metadata (SDK)
trino Trino\ConnectionConfig information_schema over HTTP
hana Hana\ConnectionConfig SYS catalog

PostgreSQL providers and transports

The postgresql engine serves every PostgreSQL-compatible server. Select the provider to pick catalog queries that are safe for it, and the transport to pick how the server is reached:

Providers: postgres (default), neon, cockroachdb, redshift. Transports: tcp (default, PDO) and http (Neon's HTTP SQL endpoint via cURL). The websocket transport is not supported by the PHP SDK (PHP has no PostgreSQL-over-WebSocket client); selecting it raises an actionable error.

The tcp transport can also reach a local Unix socket: set socket (the libpq socket directory, e.g. /var/run/postgresql) and it takes the place of host while the port is kept. A connectionString, when supplied, still takes precedence over both. Connection URLs express a TCP target only.

Tests

Integration env vars: EASYSQL_TEST_MYSQL_HOST/PORT/USER/PASSWORD/DATABASE (defaults 127.0.0.1:3306/root//easysql_test) and the matching EASYSQL_TEST_POSTGRES_* (127.0.0.1:5433/postgres/postgres/easysql_test).


All versions of easysql-connectors with dependencies

PHP Build Version
Package Version
Requires php Version >=8.2
clearsoft/easysql-common Version ^4.0
ext-pdo Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package clearsoft/easysql-connectors contains the following files

Loading the files please wait ...