MySQL : Open-Source, Relational Database Management System

learn more… | top users | synonyms

-2
votes
0answers
11 views

PMA-SQL-ERROR while importing databse in xampp [closed]

While importing database in xampp i am receiving following errors SQL query: <!-- PMA-SQL-ERROR --> <div class="error"><h1>Error</h1> <p><strong>SQL ...
3
votes
3answers
8k views

Error while restoring a Database from an SQL dump

I am extremely new to MySQL and am running it on Windows. I am trying to restore a Database from a dumpfile in MySQL, but I get the following error: $ >mysql -u root -p -h localhost -D database ...
2
votes
4answers
13k views

Broken mysql replication on slave server (error 1236)

My question is: how to fix broken mysql replication on slave server (error 1236)? server 1 (192.168.1.105) server 2 (192.168.1.106) I ran these steps to re-sync: At the master - server 1 ...
15
votes
6answers
18k views

SSD vs HDD for databases

I am trying to purchase a new Server to run MySQL Server on. This new server will be a slave of my main machine. However, this server will be dedicated for reporting only "Lots of reads and complex ...
1
vote
2answers
27 views

MySQL High Severity Error [closed]

I am completely new to MySQL. I am not a programmer or anything. I was installing the program months ago, and forgot my root password, tried to fix things and it failed. I did a system restore and ...
0
votes
1answer
371 views

Insert into a view derived from a table with a discriminator field

I am in a situation in which I have a base table with some fields and a discriminator field which could have one out of a specific set of values. From that base table, I have derived many views, one ...
0
votes
0answers
19 views

insert/update query running slow to specifi tables

I am monitoring MySQL client connections and queries run time. Found some insert/update queries to specific tables are slow than expected. I know the tables which are slow are big in size > 600K, i ...
0
votes
0answers
17 views

Confused over table_open_cache

I've been reading about the table_open_cache and I'm slightly confused about how big it should be, I've seen conflicting advice. My DB is running on MyISAM and has 199 tables. I ran into an issue ...
0
votes
0answers
32 views

Get the rank of a row based on a score I am generating from other field values

I am trying to figure out how I can get the rank of a row from a score I am generating from other field values. The score query looks something like this SELECT ((table2.field1*0.4) + ...
0
votes
0answers
27 views

Mysql - too many Deletion - Insertion

I'm creating crons for my OLAP sysetm, I have a cron that deletes the records from the summery table first and then insert the records in it again, Say Deleting 1 month records, and ...
0
votes
1answer
23 views

querying a table to find minimum of average population across all cities [closed]

Consider the table (City) structure given below I need to query on this table: Query : the minimum of average population across all cities | Field | Type | +-------------+------+ | ID ...
0
votes
0answers
41 views

Deadlocks due to foreign keys (MySQL)

We are in the process of creating a web application using mysql as a data source. We are using spring with hibernate as an ORM framework. We have hundreds of entities with relations (manyToMany \ ...
0
votes
0answers
26 views

Facing Failed to read stream error - mysql_native_password error

I have been facing the following error intermittently on MySQL. Authentication to host '127.0.0.1' for user 'root' using method 'mysql_native_password' failed with message: Reading from the ...
1
vote
1answer
50 views

Keeping an updated balance (Accounting)

I have been struggling trying to find a way to properly and reliably maintain a balance for accounts in an order/payment system. Currently, the process consists of three tables. Below example is very ...
0
votes
2answers
945 views

SQL - Cannot Add Foreign Key Constraint

Can anyone tell me why there are errors such as : Cannot Add Foreign Key Constraint And am i on the right track ? DROP DATABASE technology_university_hospital; CREATE DATABASE ...
3
votes
5answers
729 views

MySQL runs out of memory when importing innodb database

I have a small VPS with 512MB RAM and no swap (can't have any). I am importing a 1.5GB innodb database with mysql -u -p < database.sql Before the operation can finish it says : Lost connection ...
0
votes
1answer
17 views

MySQL default user

I have mysql.user table with this content: select host, user, password from user; | localhost | root | *75267AEB7355CEEE80EAB92D19FF50095AD9BB3E | | linux | root | ...
1
vote
1answer
53 views

Ansible: How to change MySQL server root password by reprovisioning the server

I have provisioned my server with Ansible playbook. I've used the root/bedrock-Ansible playbook. One of the tasks was to set up mysql server together with mysql root user password. Now I urgently ...
0
votes
1answer
1k views

MySQL PDO Cannot assign requested address

Can someone help me with this error? [08-Apr-2013 17:44:08 Europe/Berlin] PHP Warning: PDO::__construct(): [2002] Cannot assign requested address (trying to connect via tcp://****:3306) in ...
-1
votes
0answers
47 views

Count the same value from 2 tables [closed]

EDIT: http://sqlfiddle.com/#!9/d8893/11 LASTEST I want it to count between 2 tables how many pokemon i truly have but table 1 has the data of all pokemon and table 2 is inserting and confirming that i ...
1
vote
1answer
193 views

Not able to update MySQL table using Oracle: Unknown column in 'where clause' {42S22,NativeErr = 1054}

I have the following tables: MySQL table: jti_member_interact CREATE TABLE `jti_member_interact` ( `INT_MEMBER_ID` int(11) NOT NULL, `INT_ID` int(11) NOT NULL AUTO_INCREMENT, `INT_SOURCE` ...
0
votes
1answer
282 views

Change MAMP to use a lower Mysql 5.1 version

I need to have the same development environment for my PHP program. My clients test server is running on Mysql 5.1 while my local is using MAMP running Mysql 5.5. How do downgrade my mysql database ...
0
votes
2answers
41 views

MySQL: What exact commands does each privilege level allow?

I am configuring some new logins for users who have already been using the relevant MySQL servers under other logins. I would like to limit their privileges to the minimum each user needs, based on ...
0
votes
0answers
13 views

How do you create a 'shadow' database in mysql

A while back, a friend told me of a tool that would allow us to "shadow" a production database using a local database. The term shadow may be incorrect (so please correct me if so) What I ...
0
votes
1answer
174 views

Does “Connect” statement for every query indicate broken connection pooling?

there's only one client application running queries against a MySQL instance. After enabling MySQL's general query log (configured to log every query) I noticed that every query starts with a ...
0
votes
2answers
161 views

MySQL - prevent OS cache for query

On high load production server I have many sql selects which are unique or re-use will be in hours. I use SQL_NO_CACHE but this queries are still cached with OS cache. Server have 64G ram and used ram ...
0
votes
1answer
18 views

Nested set model: retrieve sub-tree containing nodes that match condition

I'm using the "nested set model" (the backend used by our web application is CakePHP and the Project model uses the TreeBehavior). This is my "project" table: +----+-------+-----------+-----+------+ ...
0
votes
1answer
47 views

Select Multiple Values from Same Column; one sql statment and split into separate columns

This post derives from following - Select Multiple Values from Same Column; one sql statment Based on this query - SELECT user_id,GROUP_CONCAT(meta_value ORDER BY id) FROM t WHERE meta_key ...
0
votes
0answers
21 views

Should I use nvarchar after I set all database utf8? [closed]

I set my whole database UTF8 by this command: ALTER DATABASE databaseName CHARSET utf8 COLLATE utf8_unicode_ci; So, should I use still nvarchar or varchar? varchar seems working for me. Beside ...
3
votes
3answers
56 views

Select Column value based on two values in another column

I am using the below table: 1 0051ML66220600132482 06:00:00 06:00:00 1538 100 0 1 2 0051ML66220600132482 06:00:00 06:00:00 1540 200 0 0 3 ...
0
votes
1answer
225 views

MySQL Entity Relationship Problem - 3-way join table?

This is a db relationship question. I have a scenario which I believe I have come up with a solution - however, I can't be sure it's a manageable one, or even correct. The scenario is as follows: ...
0
votes
0answers
9 views

Is it possible to import a CSV file into MySQL using VB.Net? [migrated]

I would like to know if it's possible to use LOAD DATA LOCAL INFILE via VB.net to import a CSV given a path to the CSV.
4
votes
1answer
20k views

MySQL 5.6 DateTime Incorrect datetime value: '2013-08-25T17:00:00+00:00' with Error Code 1292

I'm using MySQL 5.6 and I have a program that runs the following SQL statement: UPDATE m_table SET s_time = '2013-08-25T17:00:00+00:00' WHERE id = '123' against my database. Unforutnately, I get the ...
0
votes
0answers
28 views

Export MySQL Database with version compatibility

I'm trying to move a MySQL database out of my Win 2012 server & onto a shared hosting web server (Linux). I'm having problems importing the database (which imports fine into other hosted packages ...
0
votes
1answer
17 views

Run MySQL replication by schedule or on demand

I have a master-slave replication currently configured. I know this setup runs real time. Is it possible to sync only the databases on schedule (daily or weekly) or by demand? Thanks!
0
votes
1answer
179 views

Update query in a trigger

I have a configuration table: Table: refdatecol - id int(11) startdatecol varchar(100) enddatecol varchar(100) datecolTable varchar(100) This table holds the user configured column names ...
0
votes
0answers
11 views

how to export mysql database in xammp [closed]

I was getting error massage to export mysql database in xammp so please give me the address .i tried but can't access the export file in database on phpmyadmin
1
vote
3answers
15 views

Optimizing MySQL query with left joins

Ok, so first off i am going to provide a bit of information on the database structure I have 3 indexed tables that are used in this query (though one of them should probably be a weak entity, but ...
1
vote
3answers
352 views

Restore large MySQL dump thorugh EasyPHP

I am trying to upload large files on easyphp but as there is limitation on this software and large databases cannot be uploaded. Is there some other software that allows to import large databases? ...
1
vote
1answer
431 views

creating a report on the mysql jasperReport server

I have mysql local database, in it I have sample data mart. I have installed jasperReport server to my computer. Just using this tool, I want connect to the local mysql database and just create a pdf ...
0
votes
1answer
612 views

INSERT take too much time

I have in my MySQL DB a few tables Most of the time, I'm only doing INSERT in my db. I have up to 4 connections to the DB, each one inserting into a different table. There cannot be two connections ...
1
vote
1answer
19 views

“Remote” connection to a local MYSQL database on LAN

I have a mySQL (5.5.38) server running on my desktop (windows 7), I can connect just fine into any of the servers Users, and skip-networking is off when checked via show variables. I am trying to give ...
0
votes
1answer
52 views

MySQL database is going down once or twice a week, how do I diagnose?

I have a linode.com account running Ubuntu 12.04 LTS. On my server I have two instances of wordpress running with light traffic (100 to 400 users per day each) and an instance of Sendy (which is ...
1
vote
3answers
46 views

SQL self join with condition

I have table like: bu_id bu_name parent_id 1 DefaultBU NULL 601 bu1 1 602 bu2 601 603 bu3 NULL 604 bu4 603 I want to retrieve the ...
1
vote
2answers
164 views

Is there a best practice for recurring calendar events

I'm not a dba but a php programmer, so that I'm not an SQL pro. Now, I have searched in both programmers and dba stackexchange sites but the answers are too specific or not conclusive. My question is ...
0
votes
1answer
6k views

Select Multiple Values from Same Column; one sql statment

I am looking to return a list of users from a database. There are hundreds of users in the db. Each user has it's own unique user_id. All of the values that I am trying to return reside in the same ...
0
votes
1answer
107 views

MySQL - How to see the queries executing by slave io thread

We have a strange problem with MySQL replication. We have observed huge load and IO wait on server while replication is in progress. We can have information of the queries from bin-log by using ...
1
vote
2answers
797 views

Mysql Deadlock on update query on same row

My server is experiencing occasional deadlocks on two update queries on same row both using index (primary key). The conflicting queries are: UPDATE auth_user SET rep_score=185 WHERE ...
0
votes
1answer
36 views

Migrate Jira to MySql - Unknown system variable 'storage_engine'

I'm migrating JIRA in Windows from HSQL to MySQL and I got stuck with the message Unknown system variable 'storage_engine'. Though I created a backup, installed MySQL and copied J connector to libs ...
0
votes
1answer
384 views

How much RAM for a large database on a dedicated MySQL InnoDB server?

Hereunder my hardware config: CPU: 1x Intel Xeon X3470 Quad core @ 2.93GHz RAM: 4x 8GB DDR3 Disks: 2 x SATA 320GB for the system & 4 x SAS 300GB for the DB I've upgraded from 12Gb to 32Gb and ...