Two problems:
InnoDB requires that the auto_increment column be the first column in your primary key.
InnoDB does not support column-level
REFERENCES
syntax, it only supports table-levelFOREIGN KEY
constraint syntax.
This should work:
CREATE TABLE problems (
client_id BIGINT(10) NOT NULL,
problem_id INT NOT NULL AUTO_INCREMENT,
status CHAR(1) NOT NULL,
description VARCHAR(100) NOT NULL,
start_date VARCHAR(10) NOT NULL,
end_date VARCHAR(10),
PRIMARY KEY (problem_id, client_id),
FOREIGN KEY (client_id) REFERENCES clients(client_id)
);
However, this means that your clustered index (the primary key) is going to benefit lookups by problem_id, but not lookups by client_id.