Our Applicaton has a stored proc that is 17706 lines long. When I try to run this stored proc in sybase 12, it tells me that the procedure is corrupted and has to be recreated. The error also states that it was unable to build a query plan.
Is anyone aware of any bug in sybase 12 . I have managed to work it around by splitting it into 3 pieces of code. This code was running on 11.9.2.
The best option is to split the proc into smaller proc.
What might be happening is with a stored proc being close to 12,000 lines the sysprocedures may be running out of sequence number. The datatype is smallint, which means the max number of lines for an object is 32,767.
On ASE 12.5 the sequence column datatype is int, if you don't want to split the proc maybe go to 12.5