What is wrong with my SQL here 1089 - Incorrect prefix key

0 votes
CREATE TABLE `table`.`users` (
    `id` INT(11) NOT NULL AUTO_INCREMENT,
    `username` VARCHAR(50) NOT NULL,
    `password` VARCHAR(50) NOT NULL,
    `dir` VARCHAR(100) NOT NULL,
    PRIMARY KEY (`id`(11))
) ENGINE = MyISAM;

I'm getting the #1089 - Incorrect prefix key error and can't figure out what I'm doing wrong. 

Sep 3, 2022 in Database by Kithuzzz
• 38,010 points
765 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In Database

0 votes
1 answer

What is "with (nolock)" in SQL Server?

Using READ UNCOMMITED as a transaction isolation ...READ MORE

answered Feb 21, 2022 in Database by Neha
• 9,060 points
419 views
0 votes
0 answers

What is "with (nolock)" in SQL Server?

Can someone explain the ramifications of using ...READ MORE

Feb 22, 2022 in Database by Vaani
• 7,060 points
512 views
0 votes
1 answer

What is the candidate key in SQL Server?

A Candidate Key is any column or ...READ MORE

answered Feb 23, 2022 in Database by Neha
• 9,060 points
3,816 views
0 votes
1 answer

What is the SQL query to get the third highest salary of an employee from employee_table

You can try out something like this: SELECT ...READ MORE

answered Sep 27, 2018 in Database by Sahiti
• 6,370 points
11,631 views
0 votes
1 answer

What is subquery in SQL?

A subquery is a query inside another ...READ MORE

answered Oct 12, 2018 in Database by DataKing99
• 8,240 points
1,535 views
0 votes
1 answer

What is a Foreign key?

Foreign key maintains referential integrity by enforcing ...READ MORE

answered Oct 26, 2018 in Database by Sahiti
• 6,370 points
601 views
0 votes
1 answer
0 votes
1 answer

How to change the default value and to alter a column in sql?

Hi, You can try this: ALTER TABLE foobar_data CHANGE ...READ MORE

answered Jun 24, 2019 in Big Data Hadoop by Gitika
• 65,910 points
1,249 views
0 votes
1 answer

What is an index in SQL?

An index is used to speed up ...READ MORE

answered Feb 3, 2022 in Database by Vaani
• 7,060 points
450 views
0 votes
1 answer

Ordering by the order of values in a SQL IN() clause

Use MySQL's FIELD() function: SELECT name, description, ... FROM ... WHERE id ...READ MORE

answered Feb 4, 2022 in Database by Neha
• 9,060 points
4,495 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP