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
  • 704,970
  • 168
  • 1,303
  • 1,425
Developer
  • 8,228
  • 37
  • 122
  • 230
  • 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
  • 20,343
  • 11
  • 58
  • 79