Welcome to the dBforums forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions, articles and access our other FREE features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload your own photos and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact support.

If you prefer not to see double-underlined words and corresponding ads, place your cursor
here for ContentLink opt out.

Go Back  dBforums > Data Access, Manipulation & Batch Languages > ANSI SQL > IN list returned by a function

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-28-03, 15:30
confused_too confused_too is offline
Registered User
 
Join Date: Apr 2003
Posts: 1
Unhappy IN list returned by a function

I am trying to do the following with no success (ORACLE 9i, through SQLNavigator4):

FUNCTION GET_LIST RETURN VARCHAR2 IS
BEGIN
return '''GLOBAL_ID1'',''GLOBAL_ID2''';
END GET_LIST;

then I have a SQL query, which I type right in SQL Navigator, that does the following:

select * form my_table where id in (my_package.get_list())

if my function returns only one value, the query works, the moment I return a comma-delimited string, it stops working. How can I fix it?
Reply With Quote
  #2 (permalink)  
Old 04-29-03, 05:22
alligatorsql.com alligatorsql.com is offline
Registered User
 
Join Date: Jul 2001
Location: Germany
Posts: 189
Does this realy work ?

Hello,

i have never seen such syntax in PL/SQL. Are you sure that you can return a list of VARCHAR2 in a function in this way ?
If you want to return array or list of characters, I normaly use collection types or REF cursor ?!!?!

By the way, it is not a bug of your SQL Navigator ...

Best regards
Manfred Peter
(Alligator Company GmbH)
http://www.alligatorsql.com
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On