Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何使用函数获取表列的最大长度/大小?例如,如果我试图获取 VARCHAR(25) 列的大小,我想在代码中为该特定属性获取值“25”。
$row = SomeModel::model()->find(); var_dump($row->getMetaData()->columns['someCol']->size);