bender Report post Posted August 22, 2008 (edited) Hi again everyone.. I want the users of my website to be able to select data for the graph to display only 1 year, 3 years or 5 years. So I went to select the date using date() and strtotime function in php... I tested it with my database by selecting this month's data, but it says 'No Data To Display'. I don't know what is wrong...can you help me? My codes is in attachment.. thanks in advance! testing.txt Edited August 22, 2008 by Guest Share this post Link to post Share on other sites
Arindam Report post Posted August 22, 2008 (edited) Hi, Could you please change date format to m/d/Y format for Access? Please change it to $skrg = date('m/d/Y', strtotime('now')); $tarikh = date('m/d/Y', strtotime('1 august 2008')); $strQuery = "SELECT Date, Column1, Column2 FROM [Testing] WHERE Date='$skrg' AND Date>='$tarikh' ORDER BY Date"; Edited August 22, 2008 by Guest Share this post Link to post Share on other sites
bender Report post Posted August 24, 2008 Hi Arindam, I tried that, but still no graph displayed...do you know what else is wrong? Share this post Link to post Share on other sites
FusionCharts Support Report post Posted August 24, 2008 Hi, Could you please attache here the XML that is getting rendered? You can get the XML by viewing the source of the HTML generated. Share this post Link to post Share on other sites
bender Report post Posted August 25, 2008 ok here it is.. generated.txt Share this post Link to post Share on other sites
Arindam Report post Posted August 25, 2008 (edited) hi, could you please print $strQuery and after that please run this query into MS Access query and see the query result. also check date with in 'date'??? $strQuery = "SELECT Date, Column1, Column2 FROM [Testing] WHERE Date between '$tarikh' AND '$skrg' ORDER BY Date"; Edited August 25, 2008 by Guest Share this post Link to post Share on other sites
bender Report post Posted August 26, 2008 thanks Arindam.. I checked the query of selecting the dates in Access and copied them into my code and it worked well...thanks again for helping me Share this post Link to post Share on other sites