Results 1 to 3 of 3
  1. #1
    adnancanada is offline Competent Performer
    Windows XP Access 2007
    Join Date
    May 2010
    Posts
    121

    Passing list of value in store procedure

    Is there any way to pass list of parameter in store procedure .

    I have procedure call sp_GetPOinfo

    Exce sp_GetPOinfo @POnbr= (List of POs)


    Procedure contains


    Select * from POHeader where PO Nbr in (@POnbr)

  2. #2
    ranman256's Avatar
    ranman256 is online now VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,521
    i dont believe you can pass a list.

  3. #3
    HiTechCoach's Avatar
    HiTechCoach is offline MS MVP - Access Expert
    Windows 10 Access 2013 32bit
    Join Date
    Jul 2010
    Location
    Oklahoma, USA
    Posts
    702
    Quote Originally Posted by adnancanada View Post
    Is there any way to pass list of parameter in store procedure .

    I have procedure call sp_GetPOinfo

    Exce sp_GetPOinfo @POnbr= (List of POs)


    Procedure contains
    Select * from POHeader where PO Nbr in (@POnbr)
    The best you can do is to pass a string that has delimited data. Like XML or comma, etc.

    Even if you could pass an array or some other type of list, the IN() operation can't use it.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 3
    Last Post: 10-27-2015, 02:37 PM
  2. VBA passing Array arguments to procedure
    By George in forum Access
    Replies: 2
    Last Post: 05-13-2015, 10:03 AM
  3. Passing a Field Value to VBA Procedure
    By tonygg in forum Access
    Replies: 3
    Last Post: 03-10-2015, 04:32 PM
  4. Replies: 2
    Last Post: 08-29-2012, 08:01 AM
  5. Passing variable values to Stored Procedure
    By rodrigopcnet in forum Access
    Replies: 1
    Last Post: 04-14-2010, 10:35 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums