I want to create a table in mysql:--
create table app_own(app_id bigint(20) unsigned NOT NULL AUTO_INCREMENT,
sp_id bigint(20),
title varchar(30),
description varchar(60),
details LONGTEXT(1000),
primary key(app_id ),
FOREIGN KEY (user_id) REFERENCES student(sp_id));
where app_id is the primary key and sp_id is the foreign key reference from student table..
but I am getting error:--
ERROR 1064 (42000): You have an error in your SQL syntax; check the
manual that corresponds to your MySQL server version for the right
syntax to use near '(1000)0,primary key(app_id ),FOREIGN KEY (sp_id)
REFERENCE' at line 1
why the error is occuring?