Toad World® Forums

There's Always Money IN The Banana Stand. TDP seems to treat IN differently than Toad for Oracle. Anyone?


#1

I ported some SQL over from Toad for Oracle into Data Point. The IN statement in question is

…AND COUNTY_CD IN (&COUNTY_CD)

In TFO, passing &COUNTY_CD (varchar) as a comma separated list of values (‘01’,‘02’,‘03’ ) etc. worked fine.

In TDP, …AND COUNTY_CD IN (:COUNTY_CD) returns nothing for (‘01’,‘02’,‘03’). It will, however, return data for one input (‘01’) only. This also works …IN (:COUNTY_CD1, :COUNTY_CD2) etc. with one value for each parameter.

The problem is, the number of items passed can vary greatly, so I wondering why I can’t pass a list of values in TDP like I used to. It’s gonna force me to make major changes in my SQL if I can’t.

FYI, these are scripts in Toad Data Report files, not database step-by-step lines. I use TDP 3.30, Oracle 13.0.


#2

What version of TDP are you using. I have tested this in TDP 3.4 and don’t see any issues.


#3

Hi, Debbie, it’s TDP 3.30.1526. We just got it at the beginning of September, so I don’t know why we didn’t get 3.4 (grr).

Anyway, I just tested it again, and same result. Can’t pass a comma separated list to IN via a single parameter varchar.

Also, I note that you’re able to designate parameters using &ParamName. When I set the parameter marker to ‘&’ in the Options->Editor Application Code area, it ignores it, and I have to use :ParamName.


#4

TDP 3.3 have the & support disabled. It has returned in TDP 3.4 TDP 3.4 is due to be generally available mid Nov. (2 weeks or so)


#5

You can download posted Beta of 3.4 and try if you like.