• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Order by Caching is not working

#1
I upgrade to Codeigniter 3.1.9 from 3.1.4, in codeigniter 3.1.4 my order_by is working under cache, but not in 3.1.9, I checked change log there is not mentioned that it is removed or not.


example code:

$this->db->start_cache();
$this->db->order_by("COL", "DESC");
$this->db->stop_cache();


$this->db->get("MYTABLE")
Reply

#2
@mandeep242,

Did you check the error log to see if any errors where thrown?
Reply

#3
(07-26-2018, 09:04 AM)php_rocs Wrote: @mandeep242,

Did you check the error log to see if any errors where thrown?

yes I checked there is no error thrown.
Reply

#4
@mandeep242,

If you remove the cache start and stop does the order by start working again?
Reply

#5
(07-27-2018, 06:08 AM)php_rocs Wrote: @mandeep242,

If you remove the cache start and stop does the order by start working again?

I checked again the code, there is count_all_results() added, in CI 3.1.4 it is ok, but in 3.1.9 after count_all_results is removing order by
Reply

#6
@mandeep242,

How are you sure the cache is not working?
Reply

#7
(07-30-2018, 09:24 AM)php_rocs Wrote: @mandeep242,

How are you sure the cache is not working?

I checked by printing $this->db->last_query();
Reply

#8
@mandeep242,

What did or didn't you see?
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2019 MyBB Group.