Looks like your "post_id" attribute, which probably is your primary key, is not set to "auto increment" or is setup with "not null" in your Database. Take a look at the following ORM. Compare it with yours and fix your DB-sided error. And don't forget to upgrade you model via. GII!
-- -----------------------------------------------------
-- Table `mydb`.`tbl_comment`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `mydb`.`tbl_comment` ;
CREATE TABLE IF NOT EXISTS `mydb`.`tbl_comment` (
`post_id` INT NOT NULL,
`status` VARCHAR(45) NULL,
`content` TEXT NULL COMMENT ' ',
`author` VARCHAR(255) NULL,
`email` VARCHAR(255) NULL,
`url` VARCHAR(511) NULL,
`create_time` DATETIME NULL,
PRIMARY KEY (`post_id`))
ENGINE = InnoDB;
Else, if "post_id" is not your primary key and is not set as "auto increment" you can try this to fix it:
Solution 1) Make "post_id" set before save/update in php like:
$model = new Tbl_comment; //hope this is your Yii model name...
$model->post_id = 123
if(!$model->save()) {
var_dump($model->errors);
}
Solution 2) Add a default value in your database ORM on attribute "post_id". (Cause i dont know your relation and ORM right.)

-----------------------------------------
-- Table `mydb`.`tbl_comment`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `mydb`.`tbl_comment` ;
CREATE TABLE IF NOT EXISTS `mydb`.`tbl_comment` (
`post_id` INT NULL DEFAULT someDefault,
`status` VARCHAR(45) NULL,
`content` TEXT NULL COMMENT ' ',
`author` VARCHAR(255) NULL,
`email` VARCHAR(255) NULL,
`url` VARCHAR(511) NULL,
`create_time` DATETIME NULL)
ENGINE = InnoDB;
Table details:
