<?php
$conn = cubrid_connect("localhost", 33000, "demodb");
$req = cubrid_execute($conn, "SELECT * FROM code");
$row_num = cubrid_num_rows($req);
$col_num = cubrid_num_fields($req);
printf("Row Num: %d\nColumn Num: %d\n", $row_num, $col_num);
cubrid_disconnect($conn);
?>
Результат выполнения данного примера: