(PECL maxdb 1.0)
maxdb_report — Enables or disables internal report functions
$flags
) : bool
flags
One of the MAXDB_REPORT_XXX
constants.
Başarı durumunda TRUE
, başarısızlık durumunda FALSE
döner.
Örnek 1 Yordamsal kullanım
<?php
/* activate reporting */
maxdb_report(MAXDB_REPORT_ERROR);
$link = maxdb_connect("localhost", "MONA", "RED", "DEMODB");
/* check connection */
if (maxdb_connect_errno()) {
printf("Connect failed: %s\n", maxdb_connect_error());
exit();
}
/* this query should report an error */
$result = maxdb_query($link,"SELECT Name FROM Nonexistingtable WHERE population > 50000");
maxdb_close($link);
?>
Yukarıdaki örnek şuna benzer bir çıktı üretir:
Warning: maxdb_query(): -4004 POS(18) Unknown table name:NONEXISTINGTABLE <...>