MySQL : Open-Source, Relational Database Management System

learn more… | top users | synonyms

0
votes
0answers
13 views

Redesign tables, multiple foreign key and related table to same table

Hello I have this database: Table Teams is used in each one table. Match table contains teamA and teamB and round contains team that win the SET and team that start the set. But I dont know how I ...
1
vote
0answers
28 views

Optimization Tips For MYSQL Tuner/Primer

So I have a site that has a crap ton of traffic. I see a decent amount of latency when the site has over 1,000 active visitors on it. I have new relic installed and it seems Im only using 10% of the ...
0
votes
1answer
9 views

Get devices with not driver assigned

I have this related tables: And I need to get those devices with no driver assigned, in other words the device returned on this query shouldn't be on driver_has_device table since it'll not have ...
-1
votes
4answers
208 views

Database/Storage engine suggestion for a project involving heavy inserts?

I am looking into a project which involves large number of inserts daily.I will have a list of user's (for example a user set of 500k ) , for which I need to monitor daily certain activities ...
-1
votes
0answers
14 views

how to change purchase order from pending status to recieved status in erp [on hold]

i have a database for erp which is for electronic goods. i have to make purchase order from pending status to received status after user receives it. i have to reflect the change in database. should ...
1
vote
1answer
34 views

“Limit 1000,25” vs “limit 25 Offset 1000”

Recently I've found out that MySQL has a offset feature. I've been trying to find documentation about the results of offset, or the difference in between offset and the limit variant, but I can't seem ...
0
votes
0answers
8 views

Mysql recusive query

I have a table EventScheduleID Col Level 1 - 0 2 - 0 3 - 0 4 1 0 5 - 0 6 ...
0
votes
0answers
10 views

MySQL Chain Replication without log-slave-updates

I have three server's say A -> B-> C B as both Master and Slave.I have enabled log-slave-updates in B server so that replication is possible on C. So what if happens when log-slave-updates is not ...
0
votes
1answer
22 views

serial numbers for products

Let's say I'm selling 3 products. I have a products table with id and name (so that table would have 3 entries). I want each product to have a serial number, each independent from one another, but I ...
0
votes
1answer
15 views

about email trigger in mysql server [on hold]

I am trying to send email using mysql server when all my test scripts execute.I just need to send my test results in table format in email using mysql server.Could anyone help me out? I just find ...
0
votes
1answer
40 views

Does having a big table that I do not query cause the whole DB to be slower?

I have a log table that I use for logging files sent to clients. I'm not querying that table, just use it for logging (INSERT) and when I need to check when something was sent to clients, usually once ...
0
votes
1answer
28 views

Mysql error : Slave SQL Could not execute …on table

Im running a percona cluster of 3 nodes. Yesterday I needed to throw some more memory in them, so I had to power down all nodes Now I booted up and then my 3rd Node, Gave me this error : 140701 ...
1
vote
0answers
14 views

Architecture for a MySQL MDBS

My coworker and I are tasked with redesigning our current Access databases in a MySQL environment. Between the two of us, this wont be a problem but we need to connect to other external databases that ...
1
vote
1answer
16 views

Combining Tables in MySQL

I have two tables, which are very similar, in MySQL. I want to combine them into a single table with new column names. Some of the column names in Table1 or Table2 may not be used in the new ...
0
votes
0answers
15 views

output from mysqltuner.pl (from mariadb.service)

While running mysqltuner.pl script, I'm getting following message: [OK] Currently running supported MySQL version 5.5.35-MariaDB-log [OK] Operating on 64-bit architecture -------- Storage Engine ...
1
vote
1answer
19 views

How to create trigger with NOT FOR REPLICATION

I tried adding "NOT FOR REPLICATION " in many parts in the below code but ended up in the below code. I searched a lot for an example where I can see how its done with a trigger. Can any one show me ...
1
vote
1answer
26 views

MySQL Cursor Batching Process

I have a cursor in MySQL and what I want to do is rather than having an enormous cursor loop that can be up to 4000+ users in size, do it smaller batches so that the MySQL engine doesn't suffer. I ...
0
votes
0answers
11 views

mysql service failed to start when datadir changein ubuntu

I have dual Operating system on PC, windows 8 and ubuntu 14.0, and I am mostely using ubuntu because my MySql database is hosted on ubuntu. Recently when I am trying to restore my database, which is ...
0
votes
0answers
13 views

How do I stop views (large data sets) from freezing my database

I am working with tables that contain upwards of 200,000 rows. My boss wants to use views that refer to other views in order to have things be more automated. The problem is that the MySQL server ...
0
votes
1answer
33 views

MySQL replication error 1594

Is there a way to restart replication without going over MySQL :: MySQL 5.1 Reference Manual :: 16 Replication. I'm NOT seeing ANY errors on master and I'm not entirely sure why slave is ...
0
votes
1answer
16 views

Percona cluster + Wordpress blogs, low performance

We currently run ~ 900 WordPress blogs on several machines so was decided to move to load balanced environment with clustered db. I followed instructions from ...
0
votes
0answers
20 views

Innodb Deadlock During Insert

What could be the reason behind 2 inserts causing a deadlock? Here is what I get from log file: *** (1) TRANSACTION: TRANSACTION 6CA06B9, ACTIVE 6 sec inserting mysql tables in use 1, locked 1 LOCK ...
0
votes
1answer
21 views

MySQL server parameters default empty string to null

How can I set MySQL server parameters to default empty strings to null on insert? is this possible?
0
votes
1answer
31 views

getting “table is full” error even if the table size is much smaller than tablespace

Currently I am using MySQL NDBCluster 7.3.5. I have created one UNDOFILE hhme.dat with INITIAL_SIZE=200m. Also one tablespace hhmefep_tbs with DATAFILE hhmefep_tbs.dat having INITIAL_SIZE=500M ...
0
votes
0answers
14 views

Excesive use of RAM on MysqlServer

The RAM of a server where I have installed mysql is always 100% and looking at the processes that are running, MySQL is the most consumer on CPU and memory and I can see the cause of great use RAM.   ...
2
votes
1answer
26 views

MySQL InnoDB transactions with lot of delete instructions

We have a process that runs frequently and does the following steps on a mysql database of type innodb. SET autocommit = 0; DELETE FROM table WHERE category='something'; -- every 300 rows or whatever ...
0
votes
1answer
32 views

MySQL 5.1: change datadir variable value in my.cnf

Below is my system configuration: OS: RHEL5 MySQL: 5.1.73 Default datadir=/var/lib/mysql/ But, the above directory has space crunch. So, I decided to change the path. I found /u000 directory has ...
0
votes
0answers
10 views

JDBC , make connection static to improve performance [migrated]

I'm dealing with JDBC these days, I found it's really slow and i try to figure out some ways to improve the performance, I've noticed that it's slow to get the Connection object, so I'm thinking ...
0
votes
1answer
20 views

What is the difference between Com_xxx and handler_xxx?

Initially my com_delete variable and handler_xxx variables are nil. | Com_delete | 0 |+ | Handler_delete | 0 | +----------------+-------+ then I issued a delete query delete from gt ...
1
vote
1answer
40 views

How to export a MySQLtable with a longBLOB column to an Oracle database?

In MySQL I have a table: Select * from Dummy; Columns like below: id name salary binary_col 1 a 100 A.pdf 2 b 200 b.pdf 3 c 300 c.pdf 4 d 400 d.pdf 5 e 500 e.pdf ...
1
vote
0answers
15 views

Is it ever a good idea to use different storage engines on MySQL for a given database?

I asked this question at http://stackoverflow.com/questions/24477834/mixing-mysql-storage-engines-in-a-database, but it was closed as being off topic. I have needs for different functionality ...
0
votes
0answers
58 views

how to write code in order to update stock after we sell a product [migrated]

I have written following code for my sales_invoice.php if(isset($_POST['submit1'])){ // $cat_array = $_POST['category_name']; // $qua_array = $_POST['quantity']; //$mrp_array = ...
1
vote
1answer
31 views

Joining Three Tables by using IDs as Foreign Keys

I'm starting out with learning MySQL and so far I realized I need to JOIN three tables. The three tables are Users Groups Members There is a list of users, a list of groups that users can join, ...
1
vote
2answers
59 views

Checking if an Username is already in use

I am writing some scripts for my website, and I am currently focussing on checking if a username is already in use. I have tried writing a SELECT script where the datafield is selected and checks if ...
0
votes
0answers
19 views

Compare between MYSQL cluster and MYSQL server [on hold]

I have created a MYSQL cluster using network speed 100-megabit Ethernet 2 Data Node (3G RAM) 1 Management Node (3G RAM) 2 SQL Node (3G RAM) 2 HAProxy with heartbeat cluster to balance between SQL ...
1
vote
1answer
37 views

MYSQL - UPDATING multiple rows with different values in one query (for dummies)

I am trying to understand how to UPDATE multiple rows with different values and I just don't get it. The solution is everywhere but to me it looks difficult to understand. For instance, two updates ...
1
vote
1answer
35 views

Mysql super slow

I have a database of movies that I downloaded, it is around 51mb in size. One of the tables has more than 750k records(all separate insert statements(I believe this is bad)). The rest aren't so bad ...
0
votes
0answers
18 views

Which local port does MySQL Workbench forward to in 'Standard TCP/IP over SSH' connections?

So if I was to set up an ssh tunnel for MySQL in terminal I would forward remote 3306 to local 3307: ssh -L 3307:127.0.0.1:3306 user@domain.com mysql -h 127.0.0.1 -P 3307 -u user -p db When ...
0
votes
1answer
139 views

Optimize MySQL query_cache_min_res_unit

My query cache settings are the following: mysql> SHOW GLOBAL STATUS LIKE 'Q%'; +-------------------------+----------+ | Variable_name | Value | +-------------------------+----------+ ...
1
vote
3answers
234 views

What's the most efficient UUID column type

For storing a 128 bits UUID there are multiple storage options: a byte[16] column two bigint/long(64 bits) columns a CHAR(36) column - 32 hex digits + 4 dashes. a UUID database specific column, if ...
-1
votes
3answers
23 views

Setting up a root user password

I'm newbie in MySQL and i installed MySQL5.5 Server and Client in my Debian Wheezy. All i did was enter "aptitude install myqsl-server". Now, i have no idea what to do! I found a webpage that says i ...
0
votes
0answers
6 views

Large data migration from DBO to DBO - memory & time efficient?

I need to migrate data from one database (Mysql vendor, used as Alfresco DB) to custom designed Mysql DB used for reporting. Both DB's are on same DB host. My initial idea was to use view as data ...
0
votes
1answer
23 views

Audit DML operations on MySQL Tables

We have several MySQL 5.0 databases. We've been having security problems, like records being modified without authorization. We need to implement some kind of audit on DML operations identifying ...
0
votes
0answers
13 views

How to Improve mySQL Function [on hold]

I have a Stored Function and I would like to know if this can be improved by anyone better than me. (i'm 2 weeks in Stored Procedures) This accepts a DELIMITER and a string to "clean up". The idea is ...
0
votes
0answers
13 views

Best way to set up a Master Master Replication when one goes offline (Multi Writer) [on hold]

I have setup a master master replication but as its (multi writer) there are issues with keeping it synchronised. I have went through this video Percona Multi Master Hazards After watching this ...
0
votes
2answers
57 views

Avoiding MySQL Fabric to become a single point of failure

I managed to install and configure MySQL Fabric that manages multiple MySQL Server nodes. It works very well since I tested it by connecting to the Master node directly and played with the data ...
1
vote
1answer
36 views

mysql restore from data directory

I recently asked a question regarding the restoration of a pretty huge (around 300 to 400 GB) mysql database and got some nice suggestions as seen here. Now, I have backed up the data directory of ...
1
vote
1answer
22 views

Why didn't MySQL keep the innodb_file_format after loading a mysqldump

I was loading a mysql dump today when I ran into ERROR 1118 (42000) at line 279: Row size too large (> 8126) Which I thought was weird because I know I had turned on row compression and was ...
0
votes
1answer
23 views

Upgrade mysql from 5.0 to 5.5 in master-master configuration leads to broken replication

We created two new mysql servers running 5.5. Our old server were 5.0. The two servers are set up with master-master replication - this was the case for the two 5.0 servers which had no issues. We ...
0
votes
1answer
54 views

What is a good/healthy mysql query execution time?

What is a good/healthy mysql query execution time? To my calculations: The site gets 1000 unique visitors per hr 10 page view for each unique visitor 5 minutes for each unique visitor ...