skip to Main Content

Mysql – Get second highest salary in SQL

Getting Connection Lost in coorelated queries. select emp_no,salary from salaries e where 2 = (select count(distinct salary) from salaries p where p.salary>e.salary); I tried this to get second highest salary but its giving me sql connection lost every time. All…

VIEW QUESTION

Mysql – Valid SQL syntax still errors

UPDATE accounts SET lastSerialChange = CURRENT_TIMESTAMP WHERE username = 'Jayden'; UPDATE accounts SET serialChanges = '[{"serial":"D06ACE5BBE90E803590D1691FB9254B3","reason":"test","date":1695495618004}]' WHERE username = 'Jayden'; INSERT INTO serial_requests (username, serial, reason, requestedAt) VALUES ('Jayden', 'D06ACE5BBE90E803590D1691FB9254B3', 'test', 1695495618004); I am querying my database with the above,…

VIEW QUESTION
Back To Top
Search