This repo contains various database samples with PHP using PDO and Database specific Drivers. The drivers used in this sample are:
cosmosdb-mongocosmosdb-mongo-driver- MongoDB driver
mariadbmariadb-pdo- MariaDB's PDO driver
mssqlmssql-pdo- MSSQL's PDO drivermssql-driver- MSSQL specific driver
mysql-mysql-pdo- MySQL's PDO drivermysql-driver- MySQL specific driver
postgres-postgres-pdo- Postgres PDO driverpostgres-driver- Postgres specific driver
Each sample can be deployed to an Azure PHP App Service and tested with either Azure Database for MariaDB/Postgres/MySQL Instances or Azure SQL Server.
- Be sure to set the appropriate environment variables as seen in
config.php - If you encounter 'missing driver' errors, make sure these are enabled in your
php.inifile. Depending on your installation method, you may or may not need to install the relevant.dll's in your local environment. For example, themssqldriver.