I did change the id fields from TINYINT to INT (that was just a careless 
error), and fixed something else. But I still have the same problems. The 
new table schemas are below, along with the queries that don't work.

I'd love for someone to reproduce the error. As a possible workaround, 
everything seems to be fine when I prime the tables by adding a record; 
they only seem to have a problem when the tables are empty.

Thanks,
Chris



mysql_connect("localhost", "myusername", "mypassword");
mysql_db_query("DocCountry", "INSERT INTO projects (idCreator, name, 
comment) VALUES (1, 'sysmsg9.txt', 'Some file')");
mysql_db_query("DocCountry", "INSERT INTO files (idProject, name, comment) 
VALUES (1, 'sysmsg9.txt', 'Some file')");

CREATE TABLE projects ( id int(11) NOT NULL auto_increment, timestamp 
timestamp(14), idCreator int(11) DEFAULT '0' NOT NULL, name varchar(80) NOT 
NULL, comment text NOT NULL, authLevel varchar(32) NOT NULL, PRIMARY KEY 
(id) );

CREATE TABLE files ( id int(11) NOT NULL auto_increment, idProject int(11) 
DEFAULT '0' NOT NULL, idCreator int(11) DEFAULT '0' NOT NULL, name 
varchar(80) DEFAULT '0' NOT NULL, comment text NOT NULL, PRIMARY KEY (id) );

Reply via email to