Top "Mysql" questions

MySQL is a free, open source Relational Database Management System (RDBMS) that uses Structured Query Language (SQL).

'IF' in 'SELECT' statement - choose output value based on column values

SELECT id, amount FROM report I need amount to be amount if report.type='P' and -amount if report.type=…

mysql sql database
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 …

mysql mysql-error-1130
Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (38)

I am having a big problem trying to connect to mysql. When I run: /usr/local/mysql/bin/mysql start …

mysql
How do you set a default value for a MySQL Datetime column?

How do you set a default value for a MySQL Datetime column? In SQL Server it's getdate(). What is the …

mysql datetime
SQL select only rows with max value on a column

I have this table for documents (simplified version here): +------+-------+--------------------------------------+ | id | rev | content | +------+-------+--------------------------------------+ | 1 | 1 | ... | | 2 | 1 | ... | | 1 | 2 | ... | | 1 | 3 | ... | +------+-------+…

mysql sql aggregate-functions greatest-n-per-group groupwise-maximum
How to reset AUTO_INCREMENT in MySQL?

How can I reset the AUTO_INCREMENT of a field? I want it to start counting from 1 again.

mysql sql auto-increment
How do I connect to a MySQL Database in Python?

How do I connect to a MySQL database using a python program?

python mysql
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. …

mysql database innodb rename
How to output MySQL query results in CSV format?

Is there an easy way to run a MySQL query from the Linux command line and output the results in …

mysql csv quotes
MySQL ERROR 1045 (28000): Access denied for user 'bill'@'localhost' (using password: YES)

First let me mention that I've gone through many suggested questions and found no relevent answer. Here is what I'm …

mysql access-denied