Data Generation in excel through mysql
Next, let's learn about the data generation in excel through mysql. I believe you will benefit a lot after reading it. The text is not much in essence. I hope you want to achieve the data generation in excel through mysql.
5. Data extraction
The fifth part is data extraction, which is also the most common work in data analysis. The use of each function is described below.
Extract data by column
# extract SELECT city FROM data1 by column
Extract data by row
# extract SELECT * FROM data1 WHERE city='beijing' by line
Extract data by location
# extract SELECT * FROM data1 LIMIT 2 by location 5
Extract data according to conditions
# extract and calculate SELECT AVG (price) FROM data1 WHERE city='beijing' AND age30 conditionally
# data filtering INSELECT * FROM data1 WHERE city IN ('shanghai','beijing')
# data filtering ORSELECT * FROM data1 WHERE city='shanghai' OR age > 30
# data filtering (not equal) SELECT * FROM data1 WHERE city! = 'beijing'
# data filtering like (fuzzy filtering) SELECT * FROM data1 WHERE city LIKE 'bei%'
# count after filtering countifSELECT COUNT (id) AS id_count FROM data1 WHERE city='shanghai'AND age > 30
# summing sumtifSELECT SUM (price) AS price FROM data1 WHERE city='beijing' AND age after filtering