SELECT count(*) INTO @colName不用函数、但判断是少不了的
FROM information_schema.columns
WHERE table_name = 'yourTable'
AND column_name = 'yourColumn';
IF @colName = 0 THEN
alter table temp1 add ccc int(11) not null;
ELSE
alter table temp1 change ccc int(11) not null;
END IF;