In my mysql stored procedure I want try catch block but it gives error in my mysql stored procedure .
I want my select query to be in try block and if it executes correctly I want other query to execute.
code statement for mysql
BEGIN begin try select userId into user from users ; end try begin catch select 1; end catch begin finally select postId from photo where userId=user; end finally END
but it gives error is there any try catch block for mysql.