How do I migrate stored procedures with return status from SQL Server/Sybase to PostgreSQL


While migrating from SQL Server or Sybase database to PostgreSQL, how do you convert a stored procedure with return status and check if procedure call is successful.

Sample example: EXEC @return_status = sample_proc

asked 3 years ago390 views
1 Answer
Accepted Answer

If there is no need for transactional level commit or rollback statements, then you can opt to make it Function in PostgreSQL and Return Status code as per Execution logic. Function in PostgreSQL should suffice most of cases as compared to Procedure in commercial database engines.

answered 3 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions