All Questions
9 questions
1
vote
1
answer
341
views
Force Index does not work on aws mysql
I have a table sales with a compound index on (user_id, eastern_date, state)
CREATE TABLE sales (
id int not null auto_increment,
user_id int not null,
eastern_date date not null,
...
2
votes
1
answer
1k
views
MySQL performance issue when a hash join is used
I'm having an issue where the optimizer seems to be doing a full table scan and exhibiting a big performance hit when a hash join is used.
Schema and sample data:
CREATE TABLE `px_po_status` (
`...
0
votes
1
answer
2k
views
Query with left join not using index
The below query is taking about 1 second to run
SELECT `taxi_driver_mapping`.*,
concat("dpk00",
taxi_driver_mapping.mapping_payment_plan_id) AS package_text,
`people`.*,
...
0
votes
1
answer
711
views
What exactly happens when optimizer_prune_level = 1?
This documentation link states that optimizer_prune_level
Controls the heuristics applied during query optimization to prune less-promising partial plans from the optimizer search space.
Can ...
0
votes
1
answer
76
views
Analyzing a query plan for a query with TWO predicates, but index only has ONE
Note: This is from an introductory database systems course at my university so I'm not entirely sure if it matters, but for what it's worth we are being taught MySQL.
One homework question I'm doing ...
2
votes
1
answer
1k
views
What does MySQL actually use to decide which index should be used?
I know there is already similar question here like How does the database decide which Index to use. But it seems that those answers are not cool and useless.
In my development and use of MySQL, I ...
2
votes
2
answers
74
views
Create a proper index for query
I have a query that needs to be executed by a maximum of 10 concurrent processes at the same time. Each process must extract one different record from the table.
The result which I'm trying to obtain ...
1
vote
1
answer
79
views
Same database, different mysql: ENORMOUS DIFFERENCE in query time execution
I have two MySQL installations, one is on Windows with Xampp, the other one is on Mac. Machines are similar in hardware.
The databases are the same, imported in each MySQL from a DUMP file.
I ...
3
votes
1
answer
237
views
Simple SELECT takes forever, but works as a subquery. Why?
I'm running a MySQL 5.1 server and I have a MyISAM table called my_table with nearly 5 million records. Its structure is the following:
+---------------------------------------------------------------...