
October 10th, 2003, 02:48 PM
|
|
Junior Member
|
|
Join Date: Oct 2003
Posts: 1
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
The IN clause and Stored Procs
I want to pass a variable into a stored proc from a VB dll that is a comma delimited string and put this variable into an IN clause like below.
PROCEDURE GetFolders (i_FOLDERS IN VARCHAR2)
IS
BEGIN
OPEN MyCursor FOR
SELECT MyTable.*
FROM MyTable
WHERE MyTable."Folder" IN (i_FOLDERS);
END GetFolders;
The problem is that no matter what I do it always treats this variable as one big string and does not treat my comma separated folder names in the input as separate, but as one big string. It doesn't matter if I put single or double quotes around the folder names in my variable either. It works fine with just one folder name, but not right with comma delimited folder names. Is there any way to get it to treat my comma delimited input treated as separate values for the IN clause?
|