Mysql Database Table generate

Dear friend,

Hope all are fine.

I am facing a problem. please help me send your opinion.

I have a model where have properties like as


  • This is the model class for table "sms_monthly_payslips".

  • The followings are the available columns in table ‘sms_monthly_payslips’:

  • @property integer $id

  • @property string $salary_date

  • @property integer $employee_id

  • @property integer $payroll_category_id

  • @property double $amount

  • @property integer $is_approved

  • @property integer $approver_id

  • @property integer $is_rejected

  • @property integer $rejector_id

  • @property string $reason

  • @property integer $school_id

  • @property string $remark

  • @property integer $Inserted_User_ID

  • @property integer $Updated_User_ID

  • @property string $Inserted_Date

  • @property string $Updated_Date

Now i need a command, that will be generate a table like "sms_monthly_payslips" . By Yii is it possible ? if possible then how to possible ?

I don’t think you can do it.

First, you should create table with Migration.

After that you can create model by hand or generate it with Gii.