| Name | Modified | Size | Downloads / Week |
|---|---|---|---|
| README.txt | 2011-04-14 | 2.4 kB | |
| PHPODBCSQL-E v1.6.zip | 2011-04-14 | 3.9 kB | |
| PHPODBCSQL-E.zip | 2011-03-14 | 12.5 kB | |
| GNU General Public License.txt | 2011-03-12 | 28.4 kB | |
| Totals: 4 Items | 47.3 kB | 0 |
README
----------------------------
THIS IS FOR MSSQL - I have not built this with MySQL or any other SQL provider in mind although it may also work.
WHATS NEW IN THIS VERSION - 1.6
1. Setting a timezone now possible
2. Can now set an ORDER BY
3. Can now choose to show queries on the XML format document
4. Can choose to show or hide messages and queries on the XML format document
5. Minor bug fixes and code clean
6. When you first load sql.php you may not be familar with the requirements. You will now get some basic instructions.
The configuration (config.php) file MUST have the following settings put in place or the scripts will die.
- $ODBC_NAME = '';
This is the name of the ODBC connection that must exist.
- $ODBC_UID = '';
The username that will be used to connect to the server as set in the ODBC connection.
- $ODBC_PWD = '';
The password that will be used in conjunction with the username to connect to the server as set in the ODBC connection.
There are also some optionl settings you can set in the configuration file.
- $intShowMSG = 0;
If you want to show messages in the message section of the XML file then set to 1, everything else is false.
- $intShowQuery = 0;
If you want to show the performed SQL Query in the query section of the XML file then set to 1, everything else is false.
- date_default_timezone_set('UTC');
Change to your own timezone for CSV file timestamping - List of support timezones: http://www.php.net/manual/en/timezones.php
All SQL executions take place on the sql file (sql.php) below is a list of accepted URL Parameters.
- table
This is the table you want to receive results from.
- columns
These are the columns you want to receive results from. Table names MUST be defined.
- limit
The number of results you want to receive. Limit is hard coded to a maximum of 1000 whether or not you put more.
- format
Format of the results. XML and CSV are accepted.
- timestamp
If you want to append a date to files created (after the table name) then set to 1, everything else is false.
- order
You can set an order by filter now by using order=columns:desc
example 1: sql.php?table=customers&columns=firstname,surname&limit=10&format=xml&order=column:asc
example 2: sql.php?table=customers&columns=firstname,surname&limit=10&format=csv×tamp=1&order=column,column,column:desc