Starting migration of stored procedure. WIP