0

I am having query as follows which will get multiple data at a time but I don't know how to write a stored procedure for this - can anyone help me?

In code I am writing this

string deleteSQL = "Select File_Data from tblachmaster WHERE Id IN (" + gvIDs.Substring(0, gvIDs.LastIndexOf(",")) + ")";

This instead of writing like this i have to use stored procedure to execute

This is my query

Select File_Data 
From tblachmaster 
Where Id IN (1,2,3, and so on);
marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Developer
  • 8,390
  • 41
  • 129
  • 238
  • This is in sql but might give a hint towards the solution http://stackoverflow.com/questions/1069311/passing-an-array-of-parameters-to-stored-procedure – Subhash Dike Apr 25 '11 at 08:28

1 Answers1

0
CREATE PROCEDURE myProc()    
BEGIN
 SELECT File_Data from tblachmaster WHERE Id IN (1,2,3, and so on);
END;
Headshota
  • 21,021
  • 11
  • 61
  • 82