Forum Moderators: coopster

Message Too Old, No Replies

Simple query mySQL to sort but error, please help

         

vboard22

9:24 am on May 24, 2006 (gmt 0)

10+ Year Member



Hi guys

I happen to have to debug this page, and it has a querry out of database like this


$selectSQL="SELECT * FROM recentipo_item_master WHERE insertdate<= ".$fromdate." AND insertdate>=".$todate ;

I want to sort the result by a collumn in the database named Issue, so my code is

  $selectSQL="SELECT * FROM recentipo_item_master WHERE insertdate<= ".$fromdate." AND insertdate>=".$todate ORDER BY issue ASC ; 

But i got error back, Can anyone please help me?

vboard22

9:55 am on May 24, 2006 (gmt 0)

10+ Year Member



nvm i figure it out, thanks anyway

coopster

9:23 pm on May 24, 2006 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



I'm guessing you discovered that you forgot to concatenate the last part as a text string ;)

Glad you got it sorted and welcome to WebmasterWorld vboard22.

vboard22

2:37 am on May 31, 2006 (gmt 0)

10+ Year Member



Sorry I didnt come back a while, thanks for the welcome. :)