When I input a code or anything into MySQL and hit “enter” it moves down and “->” appears. It is as if the code is not going through or the code is not being read. I have attempted to download “add-ons” but I am really not sure what I am doing. This is for school and I a…
Tag: mysql
Mysql use 2 functions in 1 query
I’m trying to use 2 same functions in 1 query which is this This uses only the first function and give right result for the first latlngs only. I need the row which is almost near to the 2 latlngs (the latlngs is just example don’t care if it’s wrong <3 ) I want it to Give me the row
mysql query question about removing data from columns
This is what the table looks like right. I only want to delete the data in the two columns on the right. So let’s say i want to delete the first row Aheadworks_AdvancedSearch columns on the right. I’m sorry i’m horrible in mysql. Would this be the right syntax? How can i combine as well? Ans…
combining data from two tables with same primary key
I have a table like this: and another table like this: I want to INSERT the locations into the table1 ON t1.id=t2.id so table1 looks like this: For some reason though, when I run I get a syntax error. Does anyone know how to insert it correctly? Answer Actually you want to update Table1:
mySQL question on how to add more info to a column
Got this table containing info about customers, dates and their purchases values. Let’s say some of them bought something in November but nothing in December. Now, I am trying to have all the customers + all they spent and to use IFNULL() to the ones that have not bought anything in Dec. I am filtering …
Response like that `Error Code: 2068. LOAD DATA LOCAL INFILE file request rejected due to restrictions on access.’ When I load the data from CSV
When I run the code below in MySQL5.0, I will have a response like: Error Code: 2068. LOAD DATA LOCAL INFILE file request rejected due to restrictions on access. LOAD DATA LOCAL INFILE ‘C:Users…
SQL – copy data from one table column to another table column
As you can see from the image I have a table called wpw8_postmeta where it has four columns and I have searched for the term release and got the following results. I want to copy the results (release_date [meta_value]) to another table called wpw8_test using the post_id as foreign key/primary key. The second …
Inner join table with multiple rows/results grab the first one . Error : #1055
I have the following query : Error: #1055 – Expression #4 of SELECT list is not in GROUP BY clause and contains nonaggregated column ‘c.category_slug’ which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by One product can have…
single table parent child relationship query
I have written a query to get the items from the table which doesn’t have any child items. It’s working fine but is very slow. Any better/easier/optimized way to write the same thing? Few of the fields are these to get the idea of a structure Query should only return the 4rth item Answer Try below…
How to select the 16 highest values out of 18 values SQL?
Ok so I have changed it from columns to rows instead 😉 Im saving grades for students. I have a MySQL table called “grade” with three columns called “subject”, “points” and “userId” with 18 rows with different subjects where each subject can have one of the value…