MySQL : Open-Source, Relational Database Management System

learn more… | top users | synonyms

1
vote
2answers
45 views

ALTER primary key column from INT to BIGINT in production (MySQL 5.6.19a)

Some INNODB tables in our production database are about to hit the INT AUTO_INCREMENT limit of 2147483647 and we need to alter them to BIGINT otherwise writes will start failing. The tables are in a ...
2
votes
1answer
44 views

Mysql Cluster vs Percona/Maridb Cluster [closed]

We want to setup a mysql cluster with master-master sync replication, to provide HA so that one db for write from one app, other for write from other app. It is a webapp with high write and medium ...
0
votes
1answer
16 views

Should I exclude mysql database from multi master replication?

Running mysql in a two master replication setup. There are many databases and they are all replicating correctly including the mysql database itself. Is it safe to replicate mysql or should I exclude ...
0
votes
1answer
23 views

Creating Database Tables for Reviews functionality that incorporates Tags/Categories

I'm wanting to create some simple website functionality through a little database idea I have in order to give myself the ability to create/retrieve customer reviews based upon tags/categories. More ...
0
votes
1answer
23 views

MySQL partitioning table by date and hour

I have a table with a timestamp field. This table will have millions of rows every day so the idea is to create partitions by date and hour. Every day I will delete partitions older than 10 days and ...
0
votes
0answers
37 views

Good way to harmonize data from different databases [closed]

I have three databases (an access database with user data in-house, a MySQL database of a data provider also with user data but stored in a slightly different structure (e.g. different field names or ...
1
vote
1answer
20 views

MySQL - stay in cache priority for queries

Is there a way to tell MySQL that some queries has highter priority in cache and mustn't be popped out until it's data become invalid? The problem is that innodb cache size is rather small and data ...
1
vote
1answer
40 views

Dump All Databases in MySQL - Fails on mysql and performance_schema

I have had two attempts at dumping all databases but both have failed, one with the mysql database and then with the performance_schema database. The precised errors are:- 11:01:01 Dumping mysql - ...
1
vote
2answers
30 views

MySQL Duplicate entry for a greek word

I have a column which is unique and when I add Αγάθη and Αγαθή (which are different) it says #1062 - Duplicate entry 'Αγαθή' for key 'word'. My collation is set to utf8_general_ci. Is there any ...
0
votes
1answer
26 views

Server has antivirus. Do I need to enable external locking on MySQL?

From MySQL docs: If you only read tables with other programs, external locking is not required Assuming the bytes of MySQL files does not match viruses, the antivirus will not change the ...
3
votes
3answers
51 views

How does like query work with indexed table

I am working in Spring-java and mysql. I have to query the table of size 100k records. Table has say 10 columns. And In my sql select query I have to make like queries with %text% search on say 4 ...
0
votes
0answers
34 views

MySQL replication: most important config parameters on slave for performance on master server?

This query is almost the same as this question. But in this case, a configuration to make the master perform faster or just the same. Case We have a Master-Slave setup on a Mysql 5.0.77 - MariaDB ...
0
votes
0answers
13 views

Creating a Views on an non-relational table, can't rotate

I have a table that is set up similar to this. id | key | value1 | value2 | value 3 01 | fname | "john" | null | null 01 | lname | "doe" | null | null 01 | bday | null | YYYY-MM | ...
0
votes
0answers
14 views

How do I force MySQL to write the databse into the data files in the disk? [duplicate]

I'm running MySQL server 5.6 on Windows 2012 R2, and since the installation didn't go as planned, I had to re-install it to change the data directory path. The installer for some reasons never gave ...
0
votes
1answer
17 views

“show procedure status” displaying the non existing databases stored procedures in mysql server

i have taken a mysql server backup using mysqldump and imported the backup file in another mysql server.Import failed because of disk full issue. Only 11 databases are created out of 15 . when i issue ...
0
votes
1answer
23 views

No records in Mysql.func table even though there are stored functions in server

When i am creating a user defined function in one of my mysql server, it's not creating any row in mysql.func table . Even though i have multiple functions in my mysql server , this table is empty . ...
1
vote
0answers
24 views

Configuring slave from EC2 master to Amazon RDS slave

I am configuring replication from EC2 master to Amazon RDS instance. After starting the slave, I don't see any errors but I see slave_IO _thread is connecting. Master version:5.6.23 Slave ...
1
vote
3answers
32 views

Can I remove the middle slave in a MySQL “master -> slave -> slave” setup?

Let's say I have the following setup: Master -> Slave1 -> Slave2 I would like to remove the middle slave, Slave1, and have the following: Master -> Slave2 My gut is that I can do the following: ...
0
votes
0answers
20 views

MSDASQL returned message “ Key column information is insufficient or incorrect. Too many rows were affected by update”

Here we had two database one is SQLServer(retrieve and store attendance info) and MySQL(query from SQLServer and store as backend of PHP codes) Could you help to check and define what's the exact ...
1
vote
1answer
35 views

MySQL Update a table based on the last data from another table while grouping with conditions

I need a query to UPDATE a series of fields based on another table Table lp_plates_backup | uid | brand | model | | 1 | | | | a | Old | Error | ...
0
votes
1answer
39 views

MySQL Workbench not showing stored procedures that I have created

I have a simple stored procedure that I have just created. I have applied this script to my database This script shows up in the my list of stored procedure However, when I restart MySQL ...
1
vote
3answers
47 views

Special function slow in where but not in select

I have kind of a special problem using a levenshtein algorithm in MySql. But I don't think that it's special for levenshtein. This query: SELECT *,levenshtein(word,'Facbook') FROM Words WHERE ...
-2
votes
1answer
51 views

any advantage or disadvantage to have mysql 5.6 on a linux server over on a window server [closed]

i am planning to decide to use mysql5.6 on a window server 2012 or a linux server. Can someone gives me some general advises between the two?
0
votes
2answers
37 views

Is this query supposed to be slow?

Select * from (select tmp.userid userid, tmp.username ,tmp.likescore+tmp.commentscore+tmp.sharescore+tmp.tagscore+tmp.userscore+tmp.lsharescore+tmp.friendscore as score from ( SELECT ...
2
votes
2answers
95 views

mysql write lock

I dont add any manual locking or any transaction anything, just manual running queries from php script, and execute below two update queries at the same time update table_x set status = 'PROCESSING' ...
0
votes
0answers
14 views

Can we add different log files for different databases in MySQL for recovering the queries?

I have a master master replication system for a single database. In mysql all the logs for a single database can be recovered through binlogs and relay logs. Now I'm adding another database for the ...
0
votes
1answer
24 views

Who has deleted MySQL user from management console?

How can I find who has removed a SQL login from MySQL instance? Checked event viewer but cannot find anything.
1
vote
1answer
41 views

MySQL running fine while data files (disk) are not present. Data folder nowhere to be found

I'm running MySQL server 5.6 on Windows 2012 R2, and since the installation didn't go as planned, I had to re-install it to change the data directory path. The installer for some reasons never gave ...
1
vote
2answers
23 views

MYSQL: update field with random fixed char

would like to update all record on a field which i only want it to fill it with random either Y or N currently using: update table1 set field1=( RAND() FROM Y FOR N) which is not working, any ...
0
votes
1answer
45 views

MySQL database got corrupted

It seems that whenever I restart my Windows 7 64bit box MySQL gets corrupted. I just wanted to make this bug known as it's a serious issue. Are there any special settings I need to setup (task ...
1
vote
0answers
40 views

Get unique rows based on max of a column in mysql

I came across many solutions like the one in this question. However, they all are restricted to data from one table. I'm very very new to SQL. I'd like to get the same results as in the linked ...
0
votes
0answers
20 views

MySQL: routines removed but still in information_schema

I have a MySQL server with a lot of stored procedures (around 150). When I tried to list the routines with PHPMyAdmin it requires a lot (around 2-3 minutes) in order to load all of them. So I started ...
0
votes
2answers
33 views

case statement when grouping?

I have data that contains multiple games, each game would have several users picking it and they would all be grouped into a single week. At the end of that week I evaluate the results and assign a ...
0
votes
1answer
25 views

Need help achieving HAProxy active/passive configuration for mysql

I'm using HAProxy for mysql database backends. The database had to be master-slave. The goal is to point all mysql clients at the proxy and for all requests to go to mysql server #1 and only go to ...
-1
votes
0answers
17 views

Check if a schema contains correct columns

I'm looking at ways to test database schema. The most immediate concern is validating a schema automatically. So, how does one normally verify a schema or a series of schema without doing so ...
2
votes
2answers
38 views

An easy way to select one db dump from multiple db MySQL dump

In an urgent situation another person made a backup of all the databases from my webserver to one *.sql file (MySQL dump). Now I have a ~700 Mb file with about 20 different databases. As I only need ...
0
votes
1answer
26 views

Yet another “ERROR 1005 can't create table” question

Well, I've been looking at the ERROR 1005 questions, but I haven't been able to see my error among the issues addressed by those questions. This code is generated by MySQL Workbench under Linux. Can ...
0
votes
0answers
32 views

ClearDB Granting Created User Access

I added the ClearDB addon to Heroku, but upon using the created username to create a new database, the error appeared: Executing: CREATE SCHEMA `androidchatterdatabase` DEFAULT CHARACTER SET utf8 ; ...
0
votes
1answer
39 views

Can't see temp table from subquery

I have a query that selects data from tables and one temp table. This works fine, but there is a GROUP BY/ORDER BY combination that doesn't work well for me. Indeed, I need to order the results and ...
0
votes
0answers
15 views

Do we always need to create a new connection in order to make a select query in mysql?

Do we require to have a new connection before select always?
0
votes
0answers
28 views

How to group two query that have already been grouped

I am creating a chat system and i have two queries: The first query selects the Max(id) meaning the last message that has been received or sent by the member that is connected and that has not yet ...
0
votes
1answer
12 views

How to use mysqltuner from remote host

We do not have access to our servers with operating system console. Our production environment is Ubuntu 12. Is it possible to use mysqltuner from remote host? If yes, please provide guidelines. We ...
2
votes
1answer
38 views

Find string of decimal digits in Pi

I am trying to find the first occurrence of "12345" in the decimal expansion of $\pi$ by using MySQL. Possibly by using the Instr function? But I am stuck because it only displays the first 7 ...
0
votes
0answers
11 views

parent / child aggregate column

To start with, here is my fiddle. I have a parent / child relationship setup, I have them ordered by who they belong to, and I want to have a column called lastUpdated in which the parent has the ...
0
votes
1answer
46 views

Why does InnoDB allow a 772 byte unique constraint?

I've defined a unique constraint for two columns: A bigint and a VARCHAR(256) COLLATE utf8mb4_unicode_ci Then this error occured (which I'm already familiar with): Specified key was too long; max ...
0
votes
0answers
7 views

Should I use mysql transaction in SaaS application

Can any one elaborate whether we should use transaction for SaaS based application having simple modules like note taking and task for a team? Also if I make a Quickbook like SaaS app then do I have ...
0
votes
1answer
26 views

Pick up the name of the column by two diff column in single table

Thank you guys in advance! i am desperately need to display my data in this way, My database structure is, Column idcat, parent_id and child_id is sharing single column name, catname. I tried ...
0
votes
1answer
11 views

access denied when mysql to localhost using public ip

I would like to use the command below to connect to my Mac's local database (xx.xxx.xxx.xxx is the Mac's ip address) mysql -u cgao -h xx.xxx.xxx.xxx -p and I got the error message: ERROR 1045 ...
0
votes
1answer
23 views

Automatically purging binary logs

I'm currently trying to create an scheduled event on MySQL to purge binary logs every week. The create event statement is as follows: CREATE EVENT purgebinlogs ON SCHEDULE EVERY 1 WEEK STARTS ...
0
votes
1answer
13 views

I am trying to figure out how to get the proper results from a MySQL database [closed]

I am trying to figure out how to get the proper results from a MySQL database. Table Structure: items PN1 PN2 ------------ ------------ 702866-001 702866-001 738975-001 ...