Welcome Guest, Not a member yet? Register   Sign In
query oracle 9i problem
#1

[eluser]sansanwawa[/eluser]
Hi!
im new in CI and i have a little bit problem within my oracle 9i query...

this is my model

Code:
class M_summary extends Model
{

    function __construct()
    {
        parent::Model();
    }
    
   function getVolRealization(&$ids)
   {
$query = $this->db->query("SELECT SUM(field1+field2) AS VOL FROM table WHERE field IN (".$ids.")");    
        $res = $query->result_array();
        print_r($res);
            
   }
  
  
    
   function getInfo()
   {
           $this->db->select('DISTINCT(field),field2');
        $this->db->from('table');
        $query = $this->db->get();
        
        if($query->num_rows())
        {
            $ready = $query->result_array();
            $query->free_result();
            return $ready;
        }
        else
        {
            return false;
        }
        
        
        
            
   }

  
}


and this is my controller

Code:
class Summary extends Controller
{
    function __construct()
    {
        parent::Controller();
        $this->load->model('m_summary');
        
    }
    
    
    function index(){
    
        $data["Show"] = $this->m_summary->getInfo();
                
        $this->load->view('summary/index',$data);
    
    }
}

when i used an object getVolRealization(),the query is still just like getInfo(),i'd was try to debug my output data (print_r) and the data is still like getInfo() method... Sad

im desperate with this ...Sad,is it an influence from persistent oracle 9i connection?

could any one help me how to figure it out....

warmest regards


Thanks


Messages In This Thread
query oracle 9i problem - by El Forum - 03-08-2008, 08:06 AM
query oracle 9i problem - by El Forum - 04-12-2008, 11:22 AM
query oracle 9i problem - by El Forum - 04-13-2008, 10:57 PM



Theme © iAndrew 2016 - Forum software by © MyBB