MySQL : Open-Source, Relational Database Management System

learn more… | top users | synonyms

1
vote
1answer
135 views

MySQL: Which join is better between left outer join and inner join

Which join is better peforming if all of them provides the same result? For example, I have a two tables employees(emp_id,name, address, designation, age, sex) and work_log(emp_id,date,hours_wored). ...
0
votes
0answers
27 views

All MySQL databases are unavailable because of a broken table [duplicate]

I am using phpmyadmin to manage my MySQL DBs on local machine. I cannot see db/table contents and/or structures since one of the table in a DB has been broken. For example I have a DB which has 90 ...
1
vote
1answer
150 views

Summarize from unlimited level depth parent-child in mysql

I have 2 table master coa and coa transaction in MySQL like this, master : id | coa | id_parent | ----+------+-----------+ 1 | 1 | NULL | 2 | 11 | 1 | 3 | 111 | 2 ...
0
votes
0answers
30 views

Difference in dates between last 2 rows group by user

I have a orders table where each it has a column ord_user_fk which is the user and a ord_date which is the order date. One user can have many orders. I am trying to find the difference between the ...
1
vote
1answer
54 views

Mysql join table order by index

First Master Table CREATE TABLE `edipostingmaster` ( `ID` bigint(20) NOT NULL AUTO_INCREMENT, `applied` int(11) DEFAULT '0', `fileName` varchar(255) DEFAULT NULL, `checkNo` varchar(100) ...
1
vote
1answer
89 views

MySQL cluster: Failover between data node

Today, I do some expirements for understanding MySQL cluster better. MySQL cluster works fine: ndb_mgm> show Connected to Management Server at: localhost:1186 Cluster Configuration ...
0
votes
0answers
38 views

MySQL Event that process large data volume randomly errors

I have a MySQL event that uses a cursor to loop through a large volume of user data. Randomly, and this has only recently started happening, I am getting:- 1 queries executed, 0 success, 1 errors, 0 ...
0
votes
1answer
22 views

Query for which my.ini in use

Is it possible to query mysql server to know which configuration file is in use? Sometimes, my.cnf, my.ini. SHOW VARIABLES; -- does not have enough information here for my.ini path
-1
votes
1answer
101 views

Using C# need to drop all tables in mySQL database beginning with prefix

I have found this question answered but not specifically for C#. The answer seems to be to execute the following statements tailored to my specific database. However, I can't figure out how to use ...
0
votes
1answer
35 views

mysql auto_increment [duplicate]

I deleted 11 rows and I want the auto increment id values to reset to 6,7,8,9 … How can I achieve that without using the update statement each row one at a time. I want to find out if there is a way ...
1
vote
2answers
163 views

Messaging Database - How to handle multiple recipients

So I am trying to develop a relational database (I'm using MySQL, planning on a Java front end) where I have 3 tables (People, where I store names and relevant personal information... and Messages ...
0
votes
1answer
11 views

Completely disable all support for a certain CHAR SET in MySQL?

Is it possible to completely disallow certain charsets in MySQL and force an error and/or force everything into the server's chosen default charset?
0
votes
1answer
69 views

Any way to get database data back?

So I've entered a couple hundred rows of data into a database manually and have begun implementing a Java frontend. However, I got an unexpected result and now when I go back into RazorSQL, the ...
0
votes
0answers
15 views

MySQL - HOWTO speed up slave replication on large database / Quickly spawn slave? [duplicate]

We have a large mysql database (about 100GB on disk) that we would like to spawn a slave for. Our typical process for creating a slave is: Create a slave server Load in a mysql dump of the master ...
0
votes
2answers
283 views

MySQL - HOWTO speed up slave replication on large database / Quickly spawn slave?

We have a large mysql database (about 100GB on disk) that we would like to spawn a slave for. Our typical process for creating a slave is: Create a slave server Load in a mysql dump of the master ...
0
votes
0answers
16 views

DataController plugin for Windows?

The MySQL DataController plugins looks to be very interesting. But how can I compile/download for Windows? The wiki page syays, available under Windows too.
1
vote
1answer
37 views

Change table from InnoDB to ARCHIVE in MySQL

I try change my table from InnoDB to ARCHIVE with SQL command: ALTER TABLE data_obook ENGINE = ARCHIVE; But it always show me only error: #1005 - Can't create table 'coincity.#sql-1350_8a' (errno: ...
0
votes
1answer
19 views

How does a tagging article database look like?

I have a article website and each article has some tags. How should be my database structure? This is my article table (article): article_id (key) | article_content | article_title | ...
0
votes
1answer
33 views

Mysql dump with View dependent on user

I use simple mysqldump with only parameters are login and db details. No option of anykind is set. Now, when I recieve the dump file, it export the view in steps (I am sure you all know it, but just ...
0
votes
1answer
60 views

MySQL Cluster work well but ndb_desc doesn't work

I have deployed and configured MySQL cluster. It works fine. ndb_mgm> show Connected to Management Server at: localhost:1186 Cluster Configuration [ndbd(NDB)]2 node(s) id=2@192.168.56.2 ...
0
votes
0answers
87 views

Updating +150,000 rows using .sql file causes ERROR 2013 Lost connection to MySQL server during query

I am using ubuntu 12.04. I have a .sql file that is around 5 megabytes. When I use the command: mysql -u -p -v database query.sql The server prints out the content of the file (because of --verbose) ...
0
votes
1answer
36 views

MySQL root changed password went wrong

So basically this is what I did: mysql> use mysql; Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Database ...
0
votes
1answer
45 views

Remove question marks from database(latin1_general_ci table)?

How can I remove question marks(not diamond shaped) from a latin1_general_ci MyISAM table? I tried going back to utf8 and tried to apply things in ...
0
votes
0answers
42 views

Index on fields with a function

I have a log table. It logs visitor data (time of visit, browser, window size ...). I want to create reports. I use a query like this (MySQL): SELECT COUNT(*) as raw_views ... FROM logs WHERE ...
0
votes
2answers
72 views

Is it safe to copy DB files directly from an LVM snapshot?

I saw two different approaches for backing up database with LVM snapshot. This article suggests spawning another MySQL instance to do an SQL dump. MYSQL Performance Blog suggests that it is safe to ...
0
votes
1answer
83 views

Mysql closing immediately after new installation

I am using mysql as an backend for my webapp ,the software ran without any glitch but today it gave unexpectedly ERROR:2003 i tried many solution on the internet but none worked. so reinstalled the ...
2
votes
2answers
56 views

Give every user 3 default 'bookmark' entries

I've got a table users and a table bookmarks. The table bookmarks obviously contains pages the user wants easy access too. But, there's a new requirement now: every user gets 3 unmutable bookmarks. ...
2
votes
1answer
99 views

What is the differnent between transaction log and redo log in MySQL

I have read about MySQL. In my opinion, I see two log type is very similar. MySQL save how and when data is changed in log. Information is used for recovery of MySQL. I am confusing the function of ...
2
votes
1answer
125 views

Auto_increment value needs to be set as S1

Hi I need to set auto increment for a table as S1. I tried by altering the table and also by creating by new table I am aware how to set auto_increment but when i try to set auto increment as S1 i am ...
1
vote
3answers
108 views

How to get “mysqlbinlog” utility for Ubuntu?

I can't find "mysqlbinlog" utility in my Ubuntu server, i can see mysql, mysqldump, mysqlshow etc... command line utilities but not mysqlbinlog utility. Can someone please help me from where I can ...
2
votes
1answer
486 views

pt-heartbeat showing “Host is blocked because of many connection errors”…but connections are well under limit

I'm running MySQL in a master-slave configuration. pt-heartbeat is showing "Host is blocked because of many connection errors"...but connections are well under limit (limit is 600 connections, MySQL ...
0
votes
1answer
38 views

MySQL replication issue when master gets restarted

I have the following environment: NodeA and NodeB in NDB cluster. NodeC InnoDB outside cluster. NodeB is replication master and NodeC is slave. I have set up replication and it works fine. The ...
0
votes
1answer
38 views

Searching through ~1M slow

I've never had a database with this many rows, so I can new to keeping the search time to a minimum. I have a database table with 1.5M rows. The primary key is an auto-increment id. Then there is ...
1
vote
2answers
51 views

Query for frequency of e-mail addresses in a field

Newbie here. I know the answer is out there, but lack the vocabulary to ask the right question... I am looking for a MYSQL query which gives me the frequency of addresses in the field emailaddress. ...
1
vote
1answer
116 views

Cannot create foreign key on 2 VARCHAR(45) columns in MySQL Workbench 6.1

I'm trying to create a foreign key. The columns in both tables are VARCHAR(45) and neither is a PK, however I keep getting this error message: It is saying the PK of reference table is INT, which ...
0
votes
2answers
39 views

Migrating MySQL database structure with foreign keys fails

I am trying to set up a new testing server with a somewhat complex database structure by dumping the old database and importing it. But even though I use SET FOREIGN_KEY_CHECKS=0;, the import fails ...
2
votes
1answer
90 views

Does READ UNCOMMITTED have the same effect as AUTOCOMMIT=1?

AFAIK running transactions as READ UNCOMMITTED means that there is no lock, so every change caused by a transaction is immediately visible to other transactions. Is it correct to assume that this is ...
0
votes
2answers
131 views

DB Design Payments Table

I'm working on a Desktop application that uses a DB to store information i.e (customers, houses, proprietors, payments). So the application must accept payments from customers to company, company to ...
0
votes
1answer
163 views

Amazon RDS CPU Usage keep increasing without any long running process in Show Processlist

We are using Amazon RDS(db.m2.2xlarge), CPU usage is suddenly increasing gradually even after we reboot the DB Server. This is happening just past 2 days and we didn't give any new build recently. I ...
1
vote
3answers
569 views

Disable MySQL binary logging with log_bin variable

Default MySQL config file /etc/mysql/my.cnf installed by some debian package using APT often set log_bin variable, so binlog are enabled: log_bin = /var/log/mysql/mysql-bin.log When I want to ...
1
vote
1answer
29 views

MySQL server performance plummets

Part of our software solution is responsible for processing files that get uploaded to us by our clients. We want to process them as quickly as we can. Our system is architected so that there's a ...
0
votes
0answers
40 views

How to optimize having bit_or?

Let's start with SQLFiddle http://www.sqlfiddle.com/#!2/64fc5/1 I have some urls and I am making some tasks (crons) related to them. Task can be successful or not. I want to try to do it only three ...
5
votes
3answers
227 views

InnoDB import performance

I'm struggling with bulk importing a quite big InnoDB-Table consisting of roughly 10 Million rows (or 7GB) (which for me is the biggest table I've worked with so far). I did some research how to ...
1
vote
1answer
50 views

Schema design - Reference slightly different data in different tables

I'm trying to design a schema for a MySQL database and got stuck on the following. My database stores documents which should have relations with blocks of content. create table document ( `id` ...
0
votes
1answer
43 views

MySQL: How turning off the logging affect the performance?

OS: RHEL5 DB: MySQL 5.1.73 community edition DB size: ~1GB I have setup a testing environment and turned off all logging - general logs, binary logs, slow query logs etc. I am using Oracle ...
2
votes
2answers
88 views

ib_logfile opened with O_SYNC when innodb_flush_method=O_DSYNC

mysql will open and flush data/log files as below when innodb_flush_method=O_DSYNC Open log Flush log Open datafile Flush data O_SYNC NONE NONE fsync () ...
1
vote
1answer
62 views

InnoDB internals - checkpoint, LSN, dirty pages

I'm looking into InnoDB internals regarding buffer pool, checkpoint and dirtypage. However there isn't enough information to answer my question. When I run show global status, I can get ...
0
votes
2answers
107 views

Restore InnoDB to different machine

It was pointed to me from serverfault that the following question would be a better fit here so this is basically my original question from there. I currently have backups that were taken with ...
1
vote
2answers
103 views

Database design suggestions for a data scraping/warehouse application?

I'm looking into the database design for a data warehouse kind of project which involves a large number of inserts daily. The data archives will be further used to generate reports. I will have a ...
0
votes
1answer
19 views

MySQL Referential Integrity Issue

I'm having a lot of issues and don't really know where to look. I'm pretty sure it's a referential integrity issue and has something to do with the addition of the Professor table and the Foreign Key ...