Category "mysql"

mysql copy to another only new records

I have to 2 tables: lang temp: sku|postid|fi|en|ru (15000 records / included 200 full_products records) full_products: sku|postid|fi|en|ru|xx|zzz|aaaa|bb

Get top 10 records from db and record from current log in user

I have table which consist of some data, just I want to show the top 10 ranks from that table and at the last column I want show the rank of the user who login

Removing entries with missing links

I have two tables Number 1: adresse id name Number 2: produkte id anbieter Details: id: int name: string anbieter: int Each anbieter in

Remove records what is not contain in second table

I have to 2 tables: lang_temp (newest data): sku|postid|fi|en|ru (15000 records ) full_products: sku|postid|fi|en|ru|xx|zzz|aaaa|bbb (15200 records) postid

systax error in stored procedures

In php-myadmin . while runnig this query I am getting it like ..Import has been successfully finished, 0 queries executed. (getpaywall.com_2013-06-16.sql) But

Count field, joins, multiple selects

I have three tables. Estimates, Estimate_versions, and customers. Here is some SQL SELECT estimates.id, estimates.estimate_number, estimates.description, est

How can you find a variable length substring in MySQL?

I have several strings defined in a php script: <?php $array = [ 'foobar', 'helloworld', 'applebanana' ]; ?> From those

if statement inside mysql query to determine table to select

I would like to perform a if statment in the middle of a query, I need to find out if oc.product_type == 'clothing' or 'other' If it is clothing, then i need to

Can't connect to RDS instance from EC2 instance

From EC2 instance i-78a8df00, I'm trying to connect to RDS instance mysql.************.us-east-1.rds.amazonaws.com. They are both in the U.S. East region. I add

Use OR operand on BOOL (tinyint(1)) Fields MYSQL

Is it possible to use the OR operand when comparing two boolean values? Using MYSQL 5+ Ex. ON DUPLICATE KEY UPDATE table1.3_InMarket = (table1.3_InMarket OR

Spring Boot SSH Mysql?

I can successfully connect to my openshift mysql through workbench, how do I do the same through my spring boot application? in my application.properties: # C

Combining 2 Tables, Want to keep all Non 0 Bit on DUPLICATE KEY

I have a table with 1000 columns (yes its normalized), that is storing Biiig Daaata! I need to Insert Update new data as it becomes available overnight, and f

Mysqli query for counting number of total friends

When I have a table of users: id | login 1 Mike 2 Janet 3 Bruce And I have a table of friendships called friendlist: id | user | friend 1 1

Select Values based on Distinct Dates

I am puzzled for a while now. I have a table with phone numbers and dates(Timestamp). If a number exists more than once for a particular date, the number should

Get exact time for date mysql

How could I make a query that returns the date of today in addition to the specific hour as '2013-05-12 08:00:00'.. I'd like to make it dynamically, so how coul

'No compatible servers were found' error message

When I install the MySql Workbench, it show this message: No compatible servers were found. You'll need to cancel this wizard and install one. But I beli

Mixing two tables together

I have two tables db2: id, db1id, text, count_db1 db1: id, text db2 above is created by SELECT *, COUNT(`db1id`) AS count_db1 FROM `db2` GROUP BY `db1id

MySQL server has gone away without huge data but due to long time

The script takes too much time and so I am getting this error. I will try to optimize it. I want advice, will using, mysql_pconnect is better than mysql_connect

NameError: name '_mysql' is not defined after setting change to mysql

I have a running Django blog with sqlite3 db at my local machine. What I want is to convert sqlite3 db to mysql db change Django settings.py file to serve MySQL

My query won't work due to order by Clause

I am writing query for displaying data and added order by clause in that query. My query Is SELECT * FROM `coupons` WHERE `status` = 'A' && `type` = '