WordPress with local MySQL server: Cannot select created database as root
Even though I am root and I can log into my local mysql server as root, the WordPress Setup Configuration prevents me from selecting a database I created:
But I select one of the ones that I did not create like sys
, then it seems to connect just fine. What is happening? What am I doing wrong?
edit:
Here is what I am inputting into the WP (censoring my password), and this setup configuration generates a wp-config.php
file. Again this only seems to work for databases like sys
.
mysql wordpress localhost admin mamp
add a comment |
Even though I am root and I can log into my local mysql server as root, the WordPress Setup Configuration prevents me from selecting a database I created:
But I select one of the ones that I did not create like sys
, then it seems to connect just fine. What is happening? What am I doing wrong?
edit:
Here is what I am inputting into the WP (censoring my password), and this setup configuration generates a wp-config.php
file. Again this only seems to work for databases like sys
.
mysql wordpress localhost admin mamp
add a comment |
Even though I am root and I can log into my local mysql server as root, the WordPress Setup Configuration prevents me from selecting a database I created:
But I select one of the ones that I did not create like sys
, then it seems to connect just fine. What is happening? What am I doing wrong?
edit:
Here is what I am inputting into the WP (censoring my password), and this setup configuration generates a wp-config.php
file. Again this only seems to work for databases like sys
.
mysql wordpress localhost admin mamp
Even though I am root and I can log into my local mysql server as root, the WordPress Setup Configuration prevents me from selecting a database I created:
But I select one of the ones that I did not create like sys
, then it seems to connect just fine. What is happening? What am I doing wrong?
edit:
Here is what I am inputting into the WP (censoring my password), and this setup configuration generates a wp-config.php
file. Again this only seems to work for databases like sys
.
mysql wordpress localhost admin mamp
mysql wordpress localhost admin mamp
edited Nov 20 '18 at 18:06
Flair
asked Nov 19 '18 at 21:19
FlairFlair
12111
12111
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
It seems like you are missing the database schema api
. You can create it by simply running this query:
CREATE DATABASE api CHARACTER SET utf8 COLLATE utf8_general_ci;
When the schema is created, make sure the user (which you provided on the wordpress page) have all rights on the table. Like this:
GRANT ALL PRIVILEGES ON api.* TO root@localhost IDENTIFIED BY 'your_password';
If you still are experiencing issues, take a look at this post: Can't select database - Wordpress
I am still getting the same error.
– Flair
Nov 19 '18 at 21:35
@Flair I edited my answer.
– Mr.Turtle
Nov 19 '18 at 21:39
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 'IDENTIFIED BY 'your_password'' at line 1
– Flair
Nov 19 '18 at 21:52
The post you linked does not solve my problem.
– Flair
Nov 19 '18 at 21:58
You will have to change'your_password'
to your actual SQL-password.
– Mr.Turtle
Nov 20 '18 at 6:34
|
show 1 more comment
I managed to figure out the solution. I follow these instructions (without sudo) in order to completely purge my mysql installation: https://gist.github.com/vitorbritto/0555879fe4414d18569d. By reinstalling my mysql, everything was fixed.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53382785%2fwordpress-with-local-mysql-server-cannot-select-created-database-as-root%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
It seems like you are missing the database schema api
. You can create it by simply running this query:
CREATE DATABASE api CHARACTER SET utf8 COLLATE utf8_general_ci;
When the schema is created, make sure the user (which you provided on the wordpress page) have all rights on the table. Like this:
GRANT ALL PRIVILEGES ON api.* TO root@localhost IDENTIFIED BY 'your_password';
If you still are experiencing issues, take a look at this post: Can't select database - Wordpress
I am still getting the same error.
– Flair
Nov 19 '18 at 21:35
@Flair I edited my answer.
– Mr.Turtle
Nov 19 '18 at 21:39
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 'IDENTIFIED BY 'your_password'' at line 1
– Flair
Nov 19 '18 at 21:52
The post you linked does not solve my problem.
– Flair
Nov 19 '18 at 21:58
You will have to change'your_password'
to your actual SQL-password.
– Mr.Turtle
Nov 20 '18 at 6:34
|
show 1 more comment
It seems like you are missing the database schema api
. You can create it by simply running this query:
CREATE DATABASE api CHARACTER SET utf8 COLLATE utf8_general_ci;
When the schema is created, make sure the user (which you provided on the wordpress page) have all rights on the table. Like this:
GRANT ALL PRIVILEGES ON api.* TO root@localhost IDENTIFIED BY 'your_password';
If you still are experiencing issues, take a look at this post: Can't select database - Wordpress
I am still getting the same error.
– Flair
Nov 19 '18 at 21:35
@Flair I edited my answer.
– Mr.Turtle
Nov 19 '18 at 21:39
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 'IDENTIFIED BY 'your_password'' at line 1
– Flair
Nov 19 '18 at 21:52
The post you linked does not solve my problem.
– Flair
Nov 19 '18 at 21:58
You will have to change'your_password'
to your actual SQL-password.
– Mr.Turtle
Nov 20 '18 at 6:34
|
show 1 more comment
It seems like you are missing the database schema api
. You can create it by simply running this query:
CREATE DATABASE api CHARACTER SET utf8 COLLATE utf8_general_ci;
When the schema is created, make sure the user (which you provided on the wordpress page) have all rights on the table. Like this:
GRANT ALL PRIVILEGES ON api.* TO root@localhost IDENTIFIED BY 'your_password';
If you still are experiencing issues, take a look at this post: Can't select database - Wordpress
It seems like you are missing the database schema api
. You can create it by simply running this query:
CREATE DATABASE api CHARACTER SET utf8 COLLATE utf8_general_ci;
When the schema is created, make sure the user (which you provided on the wordpress page) have all rights on the table. Like this:
GRANT ALL PRIVILEGES ON api.* TO root@localhost IDENTIFIED BY 'your_password';
If you still are experiencing issues, take a look at this post: Can't select database - Wordpress
edited Nov 19 '18 at 21:39
answered Nov 19 '18 at 21:30
Mr.TurtleMr.Turtle
1,00221125
1,00221125
I am still getting the same error.
– Flair
Nov 19 '18 at 21:35
@Flair I edited my answer.
– Mr.Turtle
Nov 19 '18 at 21:39
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 'IDENTIFIED BY 'your_password'' at line 1
– Flair
Nov 19 '18 at 21:52
The post you linked does not solve my problem.
– Flair
Nov 19 '18 at 21:58
You will have to change'your_password'
to your actual SQL-password.
– Mr.Turtle
Nov 20 '18 at 6:34
|
show 1 more comment
I am still getting the same error.
– Flair
Nov 19 '18 at 21:35
@Flair I edited my answer.
– Mr.Turtle
Nov 19 '18 at 21:39
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 'IDENTIFIED BY 'your_password'' at line 1
– Flair
Nov 19 '18 at 21:52
The post you linked does not solve my problem.
– Flair
Nov 19 '18 at 21:58
You will have to change'your_password'
to your actual SQL-password.
– Mr.Turtle
Nov 20 '18 at 6:34
I am still getting the same error.
– Flair
Nov 19 '18 at 21:35
I am still getting the same error.
– Flair
Nov 19 '18 at 21:35
@Flair I edited my answer.
– Mr.Turtle
Nov 19 '18 at 21:39
@Flair I edited my answer.
– Mr.Turtle
Nov 19 '18 at 21:39
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 'IDENTIFIED BY 'your_password'' at line 1
– Flair
Nov 19 '18 at 21:52
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 'IDENTIFIED BY 'your_password'' at line 1
– Flair
Nov 19 '18 at 21:52
The post you linked does not solve my problem.
– Flair
Nov 19 '18 at 21:58
The post you linked does not solve my problem.
– Flair
Nov 19 '18 at 21:58
You will have to change
'your_password'
to your actual SQL-password.– Mr.Turtle
Nov 20 '18 at 6:34
You will have to change
'your_password'
to your actual SQL-password.– Mr.Turtle
Nov 20 '18 at 6:34
|
show 1 more comment
I managed to figure out the solution. I follow these instructions (without sudo) in order to completely purge my mysql installation: https://gist.github.com/vitorbritto/0555879fe4414d18569d. By reinstalling my mysql, everything was fixed.
add a comment |
I managed to figure out the solution. I follow these instructions (without sudo) in order to completely purge my mysql installation: https://gist.github.com/vitorbritto/0555879fe4414d18569d. By reinstalling my mysql, everything was fixed.
add a comment |
I managed to figure out the solution. I follow these instructions (without sudo) in order to completely purge my mysql installation: https://gist.github.com/vitorbritto/0555879fe4414d18569d. By reinstalling my mysql, everything was fixed.
I managed to figure out the solution. I follow these instructions (without sudo) in order to completely purge my mysql installation: https://gist.github.com/vitorbritto/0555879fe4414d18569d. By reinstalling my mysql, everything was fixed.
answered Nov 21 '18 at 19:36
FlairFlair
12111
12111
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53382785%2fwordpress-with-local-mysql-server-cannot-select-created-database-as-root%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown