Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

splitPageResults problem....


Shay

Recommended Posts

Hello,

 

I am trying to use the splitPageResults function that can be under the admin section.

I get an error regarding an illegal SQL query.

The SQL query is working fine by itself

 

I do the same thing as I can find in the Admin area samples.

 

Why there is a diff with the implantation of the splitPageResults as can be found under the admin section comparing to the catalog area.

 

Can someone please help me with that.

 

Thanks,

Shay

Link to comment
Share on other sites

The split page result class does really silly things like split the query up by searching for "from", "order by" etc in your SQL string.

Unfortunately, this search is case-sensitive, so if you are like me and like to construct SQL with uppercase keywords like

SELECT * FROM blah WHERE blah, it won't work with the class unless you modify it.

 

 

The differences in implementation between the 2 versions are minor I believe - I think the admin version outputs a drop-down for you to select a page, does it not?

 

What is the SQL you are having problems with and what is the error?

Link to comment
Share on other sites

Thank you for your help.

 

I found the problem. It not just the case sensitive issue, but also, I wrote the SQL query in few lines with ENTER (\n) between.

I removed that and use the . operator. It work like that. Just want to keep you informed.

 

Thanks,

Shay

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...