4. Re: SQL Statement failing in COBOL program (Jim Essinger)
date: Thu, 23 Aug 2007 10:41:57 -0600
Ok - here is the solution. Count the variables correctly and things will
work. I had repeated one field in the declare cursor statement, and when I
removed the duplicate field, I get the result that I desired. It sure helps
when SQL can match up the number of variables!
On comparing the character version of a number with an actual number field,
I found that
cast(1234567.89 as Char(10))
leaves the decimal in place. What I needed was the entire number without
seems to do what I need in one step. The result is a valid compare with the
character number "123456789".
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.