Bijeshch
New User
Joined: 23 Apr 2010 Posts: 3 Location: USA
|
|
|
|
Hi,
I am trying to use the CURRENT DATE functionality dynamically as,
"CURRENT DATE - : variable DAYS " in my query. I am getting compatibility issues.
I tried by giving
a) variable declaration as 9 (03) comp-3 but is getting compilation error.
b) variable declaration as X (10) since current date is returning a 8 byte field but is getting bind error.
Again I tried the query as "CURRENT DATE - DAYS (:variable) " as argument to the scalar function, but was not able to get through the bind errors.
The query works when "CURRENT DATE - 99 DAYS " is given. So I think its an issue with the host variable.
The SQl return code is -171 THE DATA TYPE, LENGTH, OR VALUE OF ARGUMENT nn OF function-name IS INVALID.
Please help me with this. |
|