In case you have your own slow SQL query, you can optimize it automatically here.
For the query above, the following recommendations will be helpful as part of the SQL tuning process.
You'll find 3 sections below:
SELECT
student_details.roll_number,
student_details.admission_date,
student_details.student_name,
student_details.total_marks,
student_details.progress
FROM
student_details
ORDER BY
CASE
WHEN upper(:dir) = 'ASC' THEN decode(:sort,
'student_name',
student_details.student_name,
'roll_number',
student_details.roll_number,
'admission_date',
student_details.admission_date,
'total_marks',
student_details.total_marks,
'progress',
student_details.progress) END ASC,
CASE
WHEN upper(:dir) = 'DESC' THEN decode(:sort,
'student_name',
student_details.student_name,
'roll_number',
student_details.roll_number,
'admission_date',
student_details.admission_date,
'total_marks',
student_details.total_marks,
'progress',
student_details.progress) END DESC