Category "mysql"

MySQL to update an XML attribute

In data load, it seems some XML attributes mapped incorrectly and I'm now trying to correct this, but am struggling with MySQL's handling of this XML column. I

Error: Packets out of order. Got: 1 Expected: 0

All the Solutions I found for this Problem don't work for me. I'm just loading one Dataset and after approximate 150 Request I get this Error: Error: Packets o

How to name a SQL query?

My professor is asking for me to include a query name for each and every query that is involved with this homework. I'm assuming he's referring to an alias, so

Error Code: 1822. Failed to add the foreign key constaint. Missing index for constraint

I found some threads about the error. But all the solutions doesn't work for me. I created 2 tables a user table and one for articles. Now I want to store the

mysqldump with --where clause is not working

mysqldump -t -u root -p mytestdb mytable --where=datetime LIKE '2014-09%' This is what I am doing and it returns: mysqldump: Couldn't find table: "LIKE"

Store photos in mysql database with iOS app

I am looking for a how to create a mysql database with the photos which are uploaded by my iOS app. I have already programming the picker and the upload part, b

Update a column value, replacing part of a string

I have a table with the following columns in a MySQL database [id, url] And the urls are like: http://domain1.com/images/img1.jpg I want to update all

mysql_result is defined but mysql_free_result warns it expected a resource

This code tests to see if there was a result before freeing it up: $result = mysql_query($query) or die("$query\n\n" . mysql_error()); $id = mysql_insert_id();

New records since last query in MySQL View

I am looking for a way to create a View that when queried will automatically only retrieve new records since the last query. My tables have a timestamp field fo

removing strings from a wordpress database

Hey my Wordpress site has been hacked recently and I have no backup. So I need to revert the hack. the hack placed a link in almost every table and field in my

Failed to convert from type [java.lang.Object[]] to type

I have spring web app (JPA/Hibernate + MySQL). I have two DAO classes. CustomerDAO @Entity @Table(name = "customers") public class Customer { @Id @Column

How to get product details from Magento Database with mysql query?

I just want to know about how to get product details from magento database tables. I know how to run MySQL Query and get results from database. But the problem

Laravel Migration Error: Syntax error or access violation: 1071 Specified key was too long; max key length is 767 bytes

Migration error on Laravel 5.4 with php artisan make:auth [Illuminate\Database\QueryException]

Find duplicates in the same table in MySQL

I have a table with two columns - artist, release_id What query can I run to show duplicate records? e.g. my table is ArtistX : 45677 ArtistY : 378798 Artist

How to save php socket resource in database?

I am creating a socket in php with socket_create and would like to store the received socket in a database (to access from other php code). However the socket i

Debian 10 MariaDB 'Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)'

Good evening Community, I am in despair because I cannot install MariaDB on Debian10. There are similar Stackoverflow questions but none of them helped to solv

Detect emoticons in string

I found that you need PHP 7 and MySQL 5.5 to use emoticons in a string that you want to upload to the database. I don't have these specification on my server s

Using MySQL to Create a Login page in Visual Studio 2010

I am using Visual Studio 2010. I can connect to my MySQL datababse no problem by clicking my login button. Now I can't figure out how to query the database and

I want to make where clause inside to select DB::raw in laravel

I have two tables biodata_wni and demographics, I want to count data where column akta_kwn in biodata_wni has value 1 and also the count of akta_kwn in biodata_

Writing ISO8859 data to MySQL in R (error:"could not run statement: Invalid utf8 character string")

I need to import an SAS Transfer File (.xpt) to MySQL. Because I don't own SAS, I tried a) first importing the .xpt in R b) then using dbWriteTable from the li