phpLens
 home  products examples manual  faq support forum  contact news  login store

Forums: phplens   adodb
Forum:   PHPLens Technical Support
author's name*
email*
topic*
body*
To help us reduce spam, please enter the text in the picture above

You can enter the following UBB tags: [b]bold[/b], [i]italic[/i], [red]red[/red] and [pre] [/pre]

Topic: MetaTables('TABLES') doesn't works on mysql drivers
author: Vicente Salvador   created: 12-01-2012 09:15:47 AM
Show only tables (discarding views) by using MetaTables('TABLES') doesn't works on MySQL drivers.


To work just patch the files:

drivers/adodb-mysqli.inc.php
drivers/adodb-mysql.inc.php
drivers/adodb-pdo_mysql.inc.php

Replacing current metaTablesSQL definition:

var $metaTablesSQL = "SHOW TABLES";

BY:

var $metaTablesSQL = "SELECT TABLE_NAME, CASE WHEN TABLE_TYPE = 'VIEW' THEN 'V' ELSE 'T' END FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA=SCHEMA()";
Topic: Re:MetaTables('TABLES') doesn't works on mysql drivers
author: Vicente Salvador   created: 16-01-2012 04:06:24 AM
Sorry, But forum, should be adodb forum. Please manager, move this thread to adodb forum.

View Source

email: contact#phplens.com (change # to @)     telephone (malaysia): 60-3-7947 2888     fax (malaysia): 60-3-7947 2800