PHP/MySQL Database/sqlite fetch single

Материал из Web эксперт
Перейти к: навигация, поиск

sqlite_fetch_single.php

 
<?php
    $sqldb = sqlite_open("mydatabase.db");
    $results = sqlite_query($sqldb,"SELECT name FROM employee WHERE empid < 3");
    while ($name = sqlite_fetch_single($results)) {
       echo "Employee: $name <br />";
    }
    sqlite_close($sqldb);
?>