SMFHacks.com
SMFHacks
Community Suite
SMF Gallery Pro
SMF Store
SMF Classifieds
Newsletter Pro
Downloads System Pro
Ad Seller Pro
Hacks and Mods
Latest SMF Hacks
TopTen Hacks
Styles and Themes
Add a Hack
Manage Hacks
Earn Money from Your Forum with these tips
SMF Theme Generator
SMF Package Parser
Free SMF Hosting
HostRocket Webhosting for SMF
Site Showcase
Search Forums
Advanced search
User
Welcome,
Guest
. Please
login
or
register
.
May 23, 2012, 01:08:00 pm
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Stats
Members
Total Members: 10069
Latest:
tetsujrock
Stats
Total Posts: 28682
Total Topics: 4975
Online Today: 94
Online Ever: 2482
(April 09, 2011, 07:02:45 pm)
Users Online
Users: 0
Guests: 43
Total: 43
SMFHacks.com
Forum
SMF Store
Support
SQL Syntax Error Help?!
0 Members and 2 Guests are viewing this topic.
« previous
next »
Pages:
[
1
]
Author
Topic: SQL Syntax Error Help?! (Read 2489 times)
Miyagi
Newbie
Offline
Posts: 12
SQL Syntax Error Help?!
«
on:
August 25, 2008, 07:03:35 am »
Hi,
Not the best SQL coder so really struggling to troubleshoot this.
Error:
Code:
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 'condition, value1, value2, ID_CONDITION
FROM smf_store_shippingconditions' at line 2
File: /home/fordxrtu/public_html/forum/Sources/Store.php
Line: 5524
Code:
Code:
5521: $result = db_query("
5522:
SELECT
5523:
percent, totalamount, condition, value1, value2, ID_CONDITION
5524:
FROM {$db_prefix}store_shippingconditions", __FILE__, __LINE__);
SQL Version on my server: 5.0.51a-community
Thoughts on how to fix?
Thanks,
Miyagi
Logged
Miyagi
Newbie
Offline
Posts: 12
Re: SQL Syntax Error Help?!
«
Reply #1 on:
August 25, 2008, 07:14:48 am »
2 seconds later... i think i've fixed it... the problem is
condition
is now a reserved word and needs to be 'condition'... can this be fixed properly in a new release to avoid future conflicts?
Logged
SMFHacks
Administrator
Hero Member
Offline
Posts: 9676
Re: SQL Syntax Error Help?!
«
Reply #2 on:
August 25, 2008, 07:27:09 am »
Yes it can be you can escape it with `condition` the back ticks should allow it to work.
Logged
Miyagi
Newbie
Offline
Posts: 12
Re: SQL Syntax Error Help?!
«
Reply #3 on:
August 31, 2008, 04:03:55 am »
Still having intermittent issues with this error popping up across various parts of the shipping conditions so i dug deeper.
I'd suggest updating Store.Template.php in the package as follows:
REPLACE ON LINE 5669:
Code:
percent, totalamount, condition, value1, value2, ID_CONDITION
THIS:
Code:
percent, totalamount, 'condition', value1, value2, ID_CONDITION
Will help other members running store fix any potential issues.
«
Last Edit: August 31, 2008, 04:12:04 am by Miyagi
»
Logged
SMFHacks
Administrator
Hero Member
Offline
Posts: 9676
Re: SQL Syntax Error Help?!
«
Reply #4 on:
September 02, 2008, 08:06:08 pm »
Fixed that issue for SMF Store 1.3
Logged
Pages:
[
1
]
« previous
next »
Jump to:
Please select a destination:
-----------------------------
SMFHacks.com
-----------------------------
=> News
=> Site Discussion
===> Suggestions
===> Bugs
-----------------------------
SMF Gallery Pro
-----------------------------
=> Announcements
=> Presales
=> Support
===> Bugs
===> Feature Requests
-----------------------------
SMF Store
-----------------------------
=> Announcements
=> Presales
=> Support
===> Guides and Tips
===> Feature Requests
===> Bugs
-----------------------------
SMF Classifieds
-----------------------------
=> Announcements
=> Presales
=> Support
===> Bugs
===> Feature Requests
-----------------------------
Downloads System Pro
-----------------------------
=> Announcements
=> Presales
=> Support
===> Feature Requests
===> Bugs
-----------------------------
Ad Seller Pro
-----------------------------
=> Presales
=> Support
-----------------------------
Newsletter Pro
-----------------------------
=> Presales
=> Support
===> Feature Requests
-----------------------------
Social Login Pro
-----------------------------
=> Presales
-----------------------------
Badge Awards
-----------------------------
=> Presales
-----------------------------
Tweet Topics/FB Post System
-----------------------------
=> Presales
-----------------------------
SMF Gallery Lite
-----------------------------
=> SMF Gallery Lite
-----------------------------
Modifications/Themes
-----------------------------
=> General SMF Forum
=> Modifications Talk
===> Latest Mods
===> Modification Showcase
=> Theme Talk
===> Theme Showcase
===> Latest Themes
Recent
Store IPN AMOUNT CHANGE
by
ApplianceJunk
[May 21, 2012, 08:54:11 am]
Transferring Db data from...
by
~ Phåråoh ~
[May 20, 2012, 11:06:52 am]
SMF vs PhpBB
by
channgam
[May 20, 2012, 05:58:11 am]
Any news?
by
SMFHacks
[May 19, 2012, 06:16:58 pm]
Social Login Pro domain c...
by
SMFHacks
[May 19, 2012, 05:42:37 pm]
licence information and q...
by
SMFHacks
[May 18, 2012, 03:08:38 pm]
no pictures after upgrade
by
SMFHacks
[May 17, 2012, 06:07:46 pm]
Viewers?
by
ApplianceJunk
[May 17, 2012, 02:22:07 pm]
Incorrect download counts...
by
SMFHacks
[May 17, 2012, 12:38:16 pm]
SMF V2.0.2 compatibility ...
by
~ Phåråoh ~
[May 15, 2012, 09:32:27 pm]
Random Picture
Donate to SMFHacks.com
Help Support the SMFHacks.com mod making.
Loading...