public function getTableCols(string $table): array
    {
        $schema = $this->conn->getSchemaManager();
        $tableCols = $schema->listTableColumns($table);
        $cols = [];
        foreach ($tableCols as $col) {
            $cols[$col->getName()] = [
                'length' => $col->getLength(),
                'type' => $col->getType(),
                'unsigned' => $col->getUnsigned(),
            ];
        }

        return $cols;
    }
public function getTableCols(string $table): array
    {
        $schema = $this->conn->getSchemaManager();
        $tableCols = $schema->listTableColumns($table);
        $cols = [];
        foreach ($tableCols as $col) {
            $cols[$col->getName()] = [
                'length' => $col->getLength(),
                'type' => $col->getType(),
                'unsigned' => $col->getUnsigned(),
            ];
        }

        return $cols;
    }
public function getTableCols ( string $ table ) : array { $ schema = $ this -> conn -> getSchemaManager ( ) ; $ tableCols = $ schema -> listTableColumns ( $ table ) ; $ cols = [ ] ; foreach ( $ tableCols as $ col ) { $ cols [ $ col -> getName ( ) ] = [ 'length' => $ col -> getLength ( ) , 'type' => $ col -> getType ( ) , 'unsigned' => $ col -> getUnsigned ( ) , ] ; } return $ cols ; }
Retrieve columns list for a table with type and length

@param  string $table

@return array $cols
Retrieve columns list for a table with type and length