Tag: r

60 votes
8 answers
2.9K views
Create new user in MySQL and give it full access to one database

I want to create a new user in MySQL and give it full access only to one database, say dbTest, that I create w

avatar
Emilia
0 1 0 9
asked 07 September, 2021
60 votes
16 answers
2.1K views
MySQL Error 1093 - Can't specify target table for update in FROM clause

I have a table story_category in my database with corrupt entries. The next query returns the corrupt entries:

avatar
Wei
0 1 0 9
asked 07 September, 2021
52 votes
15 answers
1.5K views
How do I see what character set a MySQL database / table / column is?

What is the (default) charset for: MySQL database MySQL table MySQL column

avatar
Keith
0 1 0 9
asked 07 September, 2021
58 votes
4 answers
2.5K views
SQL injection that gets around mysql_real_escape_string()

Is there an SQL injection possibility even when using mysql_real_escape_string() function? Consider this samp

avatar
Don
0 1 0 9
asked 07 September, 2021
59 votes
15 answers
404 views
MySQL Query GROUP BY day / month / year

Is it possible to make a simple query to count how many records I have in a determined period of time like a y

avatar
Lashawna
0 1 0 9
asked 07 September, 2021
60 votes
13 answers
2.5K views
How to truncate a foreign key constrained table?

Why doesn't a TRUNCATE on mygroup work? Even though I have ON DELETE CASCADE SET I get: ERROR 1701 (4

avatar
Hilario
0 1 0 9
asked 07 September, 2021
56 votes
15 answers
1.7K views
How can I do a FULL OUTER JOIN in MySQL?

I want to do a full outer join in MySQL. Is this possible? Is a full outer join supported by MySQL?

avatar
Alba
0 1 0 9
asked 07 September, 2021
59 votes
27 answers
1.6K views
Host 'xxx.xx.xxx.xxx' is not allowed to connect to this MySQL server

This should be dead simple, but I cannot get it to work for the life of me. I'm just trying to connect re

avatar
Lawanda
0 1 0 9
asked 07 September, 2021
47 votes
8 answers
1.3K views
MySQL: Large VARCHAR vs. TEXT?

I've got a messages table in MySQL which records messages between users. Apart from the typical ids and m

avatar
Rudolf
0 1 0 9
asked 07 September, 2021
57 votes
12 answers
677 views
"INSERT IGNORE" vs "INSERT ... ON DUPLICATE KEY UPDATE"

While executing an INSERT statement with many rows, I want to skip duplicate entries that would otherwise caus

avatar
Leonardo
0 1 0 9
asked 07 September, 2021
58 votes
11 answers
1.8K views
How can I find all the tables in MySQL with specific column names in them?

I have 2-3 different column names that I want to look up in the entire database and list out all tables which

avatar
Yolando
0 1 0 9
asked 07 September, 2021
54 votes
14 answers
2.1K views
How do I specify unique constraint for multiple columns in MySQL?

I have a table: table votes ( id, user, email, address, primary key(id), ); Now I want

avatar
Leonardo
0 1 0 9
asked 07 September, 2021
58 votes
20 answers
481 views
MySQL error code: 1175 during UPDATE in MySQL Workbench

I'm trying to update the column visited to give it the value 1. I use MySQL workbench, and I'm writi

avatar
Shanita
0 1 0 9
asked 07 September, 2021
60 votes
30 answers
1.7K views
How do I quickly rename a MySQL database (change schema name)?

The MySQL manual at MySQL covers this. Usually I just dump the database and reimport it with a new name. This

avatar
Freida
0 1 0 9
asked 07 September, 2021
55 votes
8 answers
2.4K views
What's the difference between utf8_general_ci and utf8_unicode_ci?

Between utf8_general_ci and utf8_unicode_ci, are there any differences in terms of performance?

avatar
Adolfo
0 1 0 9
asked 07 September, 2021
60 votes
29 answers
1.5K views
Argument list too long error for rm, cp, mv commands

I have several hundred PDFs under a directory in UNIX. The names of the PDFs are really long (approx. 60 chars

avatar
Frederick
0 1 0 9
asked 07 September, 2021
65 votes
2 answers
2.2K views
How do SO_REUSEADDR and SO_REUSEPORT differ?

The man pages and programmer documentations for the socket options SO_REUSEADDR and SO_REUSEPORT are different

avatar
Thurman
0 1 0 9
asked 07 September, 2021
55 votes
16 answers
1.7K views
How to force cp to overwrite without confirmation

I'm trying to use the cp command and force an overwrite. I have tried cp -rf /foo/* /bar, but I am still

avatar
Dwain
0 1 0 9
asked 07 September, 2021
68 votes
9 answers
1.1K views
How does "cat << EOF" work in bash?

I needed to write a script to enter multi-line input to a program (psql). After a bit of googling, I found th

avatar
Eddie
0 1 0 9
asked 07 September, 2021
57 votes
27 answers
1.5K views
Convert DOS line endings to Linux line endings in Vim

If I open files I created in Windows, the lines all end with ^M. How do I delete these characters all at once?

avatar
Daniel
0 1 0 9
asked 07 September, 2021