Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: Database: MySql
 Converting from Access to MySQL - code errors
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

endomorph
Junior Member

United Kingdom
128 Posts

Posted - 31 December 2009 :  05:24:58  Show Profile
I'm in the process of converting my site from Access to MySQL. I have done the database conversion and uploaded but when viewing the site I get -

[MySQL][ODBC 3.51 Driver][mysqld-5.0.51b-community-nt]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 '[pmcount] FROM FORUM_MEMBERS , FORUM_PM WHERE FORUM_MEMBERS.M_NAME = 'Timeshar' at line 1

/test/forum/inc_header.asp, line 505

The code relates to -


if strDBType = "access" then
		strSqL = "SELECT count(M_TO) as [pmcount] "
	else
        	strSqL = "SELECT count(M_TO) as pmcount"
    	end if
	strSql = strSql & " FROM " & strMemberTablePrefix & "MEMBERS , " & strTablePrefix & "PM "
	strSql = strSql & " WHERE " & strMemberTablePrefix & "MEMBERS.M_NAME = '" & strDBNTUserName & "'"
	strSql = strSql & " AND " & strMemberTablePrefix & "MEMBERS.MEMBER_ID = " & strTablePrefix & "PM.M_TO "
	strSql = strSql & " AND " & strTablePrefix & "PM.M_READ = 0 "

Set rsPM = my_Conn.Execute(strSql)



which is part of the PM mod. Line 505 is the Set rsPM = my_Conn.Execute(strSql)

Any ideas ?

Need help with your Snitz ? Most Snitz & ASP custom coding undertaken. Email for info | Search Engine Optimisation

endomorph
Junior Member

United Kingdom
128 Posts

Posted - 31 December 2009 :  06:00:45  Show Profile
Ooops simple error - forgot to change DB type in config.asp

But now I have other problems which are mainly -

Microsoft VBScript runtime error '800a000d'

Type mismatch

on strings which should be numbers.

Any hints

Need help with your Snitz ? Most Snitz & ASP custom coding undertaken. Email for info | Search Engine Optimisation
Go to Top of Page

ruirib
Snitz Forums Admin

Portugal
26364 Posts

Posted - 31 December 2009 :  06:47:24  Show Profile  Send ruirib a Yahoo! Message
Did you check this: http://forum.snitz.com/forum/topic.asp?TOPIC_ID=55925


Snitz 3.4 Readme | Like the support? Support Snitz too
Go to Top of Page

endomorph
Junior Member

United Kingdom
128 Posts

Posted - 31 December 2009 :  08:47:15  Show Profile
Thank you, thank you, thank you !!!!

Need help with your Snitz ? Most Snitz & ASP custom coding undertaken. Email for info | Search Engine Optimisation
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.19 seconds. Powered By: Snitz Forums 2000 Version 3.4.07