The uploads module does not appear to work properly when disabling adodb_lite.
The following error appears when trying to list a category:
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''1'' at line 1
Is it possible to make this work without adobdb_lite?
Upload Module without adodb_lite
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
- Location: Fernie British Columbia, Canada
Re: Upload Module without adodb_lite
Of course it's possible, but first I need to know a bit more information:
a) which version of CMS
b) which version of Uploads
c) which database package you want it to use
d) connecting to what database
e) exactly what tag you're using in the page or template, and when you get the error.
Thanks
a) which version of CMS
b) which version of Uploads
c) which database package you want it to use
d) connecting to what database
e) exactly what tag you're using in the page or template, and when you get the error.
Thanks
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Re: Upload Module without adodb_lite
a) 1.0-beta2
b) 1.2.3
c) adodb (I downloaded version 490 from the adodb website)
I am also trying to embed gallery2 into cmsms. Gallery 2 does not successfully embed unless adodb_lite is not used.
d) mysql 5
e)
{cms_module module="Uploads" category="bulletin" sortorder="date_desc" template="bulletin" mode="summary"}
b) 1.2.3
c) adodb (I downloaded version 490 from the adodb website)
I am also trying to embed gallery2 into cmsms. Gallery 2 does not successfully embed unless adodb_lite is not used.
d) mysql 5
e)
{cms_module module="Uploads" category="bulletin" sortorder="date_desc" template="bulletin" mode="summary"}
Re: Upload Module without adodb_lite
SQL Errors on install:
Code: Select all
(mysql): CREATE TABLE cms_module_uploads ( upload_id INTEGER NOT NULL, upload_category_id INTEGER, upload_name VARCHAR(255), upload_author VARCHAR(255), upload_summary VARCHAR(255), upload_description TEXT, upload_ip VARCHAR(255), upload_size INTEGER, upload_date DT, upload_key VARCHAR(255), PRIMARY KEY (upload_id) )TYPE=MyISAM 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'DT, upload_key VARCHAR(255), PRIMARY KEY (upload_' at line 10
ADOConnection._Execute(CREATE TABLE cms_module_uploads (
upload_id INTEGER NOT NULL,
upload_category_id INTEGER,
upload_name ..., false) % line 861, file: adodb.inc.php
ADOConnection.Execute(CREATE TABLE cms_module_uploads (
upload_id INTEGER NOT NULL,
upload_category_id INTEGER,
upload_name ...) % line 269, file: adodb-datadict.inc.php
ADODB_DataDict.ExecuteSQLArray(Array[1]) % line 48, file: method.install.php
include(/home/spwels/spwels.org/docs/site/modules/Uploads/method.install.php) % line 1077, file: class.module.inc.php
CMSModule.Install() % line 363, file: class.module.inc.php
(mysql): CREATE TABLE cms_module_uploads_downloads ( download_id INTEGER NOT NULL, file_id INTEGER, download_date DT, download_ip VARCHAR(255), download_user VARCHAR(255), PRIMARY KEY (download_id) )TYPE=MyISAM 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'DT, download_ip VARCHAR(255), download_user VARCHAR(255)' at line 4
ADOConnection._Execute(CREATE TABLE cms_module_uploads_downloads (
download_id INTEGER NOT NULL,
file_id INTEGER,
downloa..., false) % line 861, file: adodb.inc.php
ADOConnection.Execute(CREATE TABLE cms_module_uploads_downloads (
download_id INTEGER NOT NULL,
file_id INTEGER,
downloa...) % line 269, file: adodb-datadict.inc.php
ADODB_DataDict.ExecuteSQLArray(Array[1]) % line 63, file: method.install.php
include(/home/spwels/spwels.org/docs/site/modules/Uploads/method.install.php) % line 1077, file: class.module.inc.php
CMSModule.Install() % line 363, file: class.module.inc.php
(mysql): CREATE TABLE cms_module_uploads_categories ( upload_category_id INTEGER NOT NULL, upload_category_name VARCHAR(255), upload_category_description TEXT, upload_category_path VARCHAR(255), upload_category_listable INTEGER, PRIMARY KEY (upload_category_id) )TYPE=MyISAM (mysql): CREATE TABLE cms_module_uploads_categories ( upload_category_id INTEGER NOT NULL, upload_category_name VARCHAR(255), upload_category_description TEXT, upload_category_path VARCHAR(255), upload_category_listable INTEGER, PRIMARY KEY (upload_category_id) )TYPE=MyISAM 1050: Table 'cms_module_uploads_categories' already exists
ADOConnection._Execute(CREATE TABLE cms_module_uploads_categories (
upload_category_id INTEGER NOT NULL,
upload_category_name VARCHAR(255),
u..., false) % line 861, file: adodb.inc.php
ADOConnection.Execute(CREATE TABLE cms_module_uploads_categories (
upload_category_id INTEGER NOT NULL,
upload_category_name VARCHAR(255),
u...) % line 269, file: adodb-datadict.inc.php
ADODB_DataDict.ExecuteSQLArray(Array[1]) % line 80, file: method.install.php
include(/home/spwels/spwels.org/docs/site/modules/Uploads/method.install.php) % line 1077, file: class.module.inc.php
CMSModule.Install() % line 363, file: class.module.inc.php
Re: Upload Module without adodb_lite
Fix:
------------------------------------------------------
Uploads.module.php Line 3048-50 reads:
$query = "SELECT COUNT(*) AS count FROM ".cms_db_prefix()."module_uploads
WHERE upload_category_id = ?";
$dbresult = $db->Execute( $q, array( $category_id ) );
Should be:
$q = "SELECT COUNT(*) AS count FROM ".cms_db_prefix()."module_uploads
WHERE upload_category_id = ?";
$dbresult = $db->Execute( $q, array( $category_id ) );
------------------------------------------------------
method.install.php line 40 reads:
upload_date DT,
Should be:
upload_date DATETIME,
method.install.php line 53 reads:
download_date DT,
Should be:
download_date DATETIME,
------------------------------------------------------
------------------------------------------------------
Uploads.module.php Line 3048-50 reads:
$query = "SELECT COUNT(*) AS count FROM ".cms_db_prefix()."module_uploads
WHERE upload_category_id = ?";
$dbresult = $db->Execute( $q, array( $category_id ) );
Should be:
$q = "SELECT COUNT(*) AS count FROM ".cms_db_prefix()."module_uploads
WHERE upload_category_id = ?";
$dbresult = $db->Execute( $q, array( $category_id ) );
------------------------------------------------------
method.install.php line 40 reads:
upload_date DT,
Should be:
upload_date DATETIME,
method.install.php line 53 reads:
download_date DT,
Should be:
download_date DATETIME,
------------------------------------------------------