close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

There is an error in your SQL syntax on live server

Thread began 6/05/2018 2:21 pm by Robert Crespo | Last modified 6/05/2018 4:54 pm by Ray Borduin | 1400 views | 6 replies |

Robert Crespo

There is an error in your SQL syntax on live server

Help! I am trying to test my work on my live server (Hostgator) and I am getting the following error message

"There is an error in your SQL syntax"

The funny thing is, my development website on my local machine (Windows with WAMP) works great. Can you please take a look at my sample index page that I am trying to test and let me know what is wrong?

Thank you,
Robert

Sign in to reply to this post

Ray BorduinWebAssist

Open your rsobj.php page and change the debug setting to true near the top of the file. That should show you a better error message.

Sign in to reply to this post
Did this help? Tips are appreciated...

Robert Crespo

Ray, I opened the rsobj.php and did not see a debug setting. Can you please be more specific as to which line I need to change?

Thanks,
Robert

Sign in to reply to this post

Ray BorduinWebAssist

I've attached the current beta version of the rsobj.php file. The debug setting is on line 11

Attached Files
rsobj.php
Sign in to reply to this post
Did this help? Tips are appreciated...

Robert Crespo

The debug worked! Here is the error message I am getting:

SELECT SQL_CALC_FOUND_ROWS * FROM products WHERE ProductID = -1 ORDER BY ProductID ASC LIMIT 0,1

Unknown column 'ProductID' in 'where clause'

Any reason why the page is working on my WAMP server but not my live Hostgator server?

Robert

Sign in to reply to this post

Ray BorduinWebAssist

That means your products table doesn't have a column named ProductID on your live server. Make sure the database table was created properly on the live server.

Sign in to reply to this post
Did this help? Tips are appreciated...

Robert Crespo

What an idiot I am! LOL! I made some adjustments to my products table structure and forgot to change the ProductID field to ProdID like it is on my live server. Once I changed the name back from ProductID to ProdID the page worked fine. Thanks for the help!

Robert

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...