Hi All,
I am running a query with a subuery in an IN clause and am getting back zero results. The query is;
If I run just the subquery I get the expected results (155 rows to be exact) of numbers returned as strings. If I change the query to;
I also get no results, but changing the "TO_CHAR (149)" to " '149' " I do get results.
The dial_digit field is a string and the spd_num field is a number.
Any help would be appreciated.
Thx, Tim
I am running a query with a subuery in an IN clause and am getting back zero results. The query is;
Code:
SELECT COUNT(*), dial_digit
FROM calldetail
WHERE dial_digit IN (SELECT TO_CHAR (spd_num) FROM speed)
GROUP BY dial_digit
ORDER BY dial_digit
If I run just the subquery I get the expected results (155 rows to be exact) of numbers returned as strings. If I change the query to;
Code:
SELECT COUNT(*), dial_digit
FROM calldetail
WHERE dial_digit IN (TO_CHAR (149))
GROUP BY dial_digit
ORDER BY dial_digit
I also get no results, but changing the "TO_CHAR (149)" to " '149' " I do get results.
The dial_digit field is a string and the spd_num field is a number.
Any help would be appreciated.
Thx, Tim