Hi:
After the data base is opened, I can see the number of records of my query but when I try to access to the fields ($q->f('anyfield'))always returs the same error:
Notice: Undefined index: Id in C:...\db_mysql.inc on line 227
Notice: Undefined index: name in C:...\db_mysql.inc on line 227
Notice: Undefined index: birthdate in C:...\db_mysql.inc on line 227
where Id es a field in my table and db_mysql.inc is a library of phplib.
Does anyone know why?
This is the code:
include('../activo/db_mysql.inc');
$q = new DB_Sql;
$q->Host = "databasehost";
$q->Database = "database_name";
$q->User = "username";
$q->Password = "pass";
echo $q->num_rows(); //returns the number of records with no errror
echo $q->f('name'); //this line fire the error
thanks