C
C#15mo ago
Muaazz

✅ need help in database

No description
7 Replies
Salman
Salman15mo ago
isn't your foreign key EmployeeID need to be INT or is it string or GUI ? also what's the error
Muaazz
MuaazzOP15mo ago
i tried INT but not working also the error is i cant add the FOREIGN KEY
Buddy
Buddy15mo ago
Are you sure there are no visible error messages? If it can detect the errors it should also show the error message(s)
Marvin
Marvin15mo ago
you have to execute to see errors
Muaazz
MuaazzOP15mo ago
it error is visible but i tried all the thing i know yes i execute its saying Incorrect syntax near 'AUTO_INCREMENT'
Pobiega
Pobiega15mo ago
because thats not valid T-SQL ID_column INT NOT NULL IDENTITY(1,1) PRIMARY KEY, SQL isnt just SQL, there are many dialects MSSQL and SQL Express use T-SQL this is not the same as mysql dialect, or postgres
Muaazz
MuaazzOP15mo ago
thanks now its working

Did you find this page helpful?