Solved

Interbase 5.5 "Passing an Array into a Stored Procedure"

Posted on 2003-11-18
2
2,704 Views
Last Modified: 2013-12-09
I need to be able to pass in multiple values into a single parameter.

Example

Select EmployeeName
from employee
Where EmployeeID in (:ParameterValues)


Output would be multiple EmployeeNames


I can't seem to define an Input Paramter as an Array and I can't seem to declare a variable as an Array.

The current syntax for the Input Param is:
EmployeeID Integer[10]

The current syntax for the variable declaration is:
Delcare Variable EmpID Integer[10];


I have tried several variations of the above with no luck.

I am using Interbase Version 5.6 on a windows 2000 platform.


Thanks,
matchbx27
0
Comment
Question by:matchbx27
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 1

Accepted Solution

by:
chart11610 earned 500 total points
ID: 9772900
Interbase stored procedures do not support the passing of arrays to the best of my knowledge.  All variable are passed by Value (copy) and must remain language independent.   The SQL gurus that I have worked with over the years try to avoid arrays.  

One possible solution is to store the list of employees in a staging table, and then use that table within the SQL of the stored procedure.
0
 

Author Comment

by:matchbx27
ID: 9772957
A little backgound...

I am currently creating more reports in an Interbase database that came with an application my company purchased.

The Solution you mentioned is the way it is currently being handled.  I don't have alot of confidence in some the work I have seen from the company and their Product.  I just wanted to see if something better, faster was available.


Thanks,
matchbx27
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

A company’s centralized system that manages user data, security, and distributed resources is often a focus of criminal attention. Active Directory (AD) is no exception. In truth, it’s even more likely to be targeted due to the number of companies …
Recently, Microsoft released a best-practice guide for securing Active Directory. It's a whopping 300+ pages long. Those of us tasked with securing our company’s databases and systems would, ideally, have time to devote to learning the ins and outs…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question