I have a report connecting to Oracle. There is a where claause that used to say this from tumour t, tumour_source ts, patient p where (t.dco_status ='Y' or t.dco_status ='M') and ts.patient_id = t.patient_id and ts.tumour_id = t.tumour_id and t.patient_id = p.patient_id and ts.batch_number BETWEEN 2399 and 2408 and ts.supplier_code = 'DEATH'
Field ts.batch_number is defined in the database as a number.
I want to set the start and end batches as parameters. So - I have defined 2 parameter fields and I get prompted for them when refreshing the report. But.... If I have this line and ts.batch_number BETWEEN '{?bstart}' and '{?bend}'
I get nothing, I think because it is passing over strings and comparing them with numbers.
But if I get rid of the quotes and use this and ts.batch_number BETWEEN {?bstart} and {?bend}
I then get a ORA-00911 error. I tried using quotes and to_number as well but it didn't like that either.
How do I get around this.
------------- Andy
|