How To Correct A Cexception Caused Due To Case Sensitive Column Name

I’m new to Yii framework. My application designed with Yii 1.0 works fine in local system. When I migrated the same in production, I got


CException: Property not defined

exception.

The problem was :

Date field in a table was case sensitive. In my local system, Date was


Date

, but in production Date was


date

. This caused an exception.

To correct this exception, I used get and set methods as shown below -




public function getdate()

{

    return $this->date;

}


public function setdate($date)

{

    $this->date = $date;

}



But I’m not sure if I can use this to correct the exception. Is it the right way to correct such exceptions. Please help as I’m the only one working on this in my office and no guide.