Jump to content

Stored Procedure

Recommended Posts

I have a table: Named  HighScores  

"INSERT HighScores 
VALUES ('Bob', 2500, '2 Jan 2013 13:13'),
           ('Jon', 1500, '2 Jan 2013 13:15'),
       ('Amy', 3500, '2 Jan 2013 13:18')"

I want to create a stored procedure that would:

The score must show the TOP 5 or so people.

Show your position on the high score board

Show the person in front and below you on the high score board.

If the scores are tied, the person who got it the most recent is shown higher.

Can anybody assist me please?

Link to post
Share on other sites
  • 3 months later...

It doesn't work for MySQL Workbench:

SELECT * FROM Customers
EXEC SelectAllCustomers;

But it is working:


T * FROM category;
END //

CALL SelectCategory();    


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...