Linq to Sql: Generic Stored Procedures
Posted
by
Eric
on Stack Overflow
See other posts from Stack Overflow
or by Eric
Published on 2011-01-04T03:40:44Z
Indexed on
2011/01/04
3:54 UTC
Read the original article
Hit count: 224
Hello everyone,
I am using Linq-to-Sql for a C# application and am currently working on some stored procedures. The application is for a newspaper, and a sample stored procedure is the following:
ALTER PROCEDURE dbo.Articles_GetArticlesByPublication
@publicationDate date
AS
SELECT
*
FROM
Articles
WHERE
Articles.PublicationDate=@publicationDate
Anyway, this query gets all of the articles where the publication date is equal to the argument (publicationDate). How can I alter this so that the argument can handle multiple publication dates?
Also, I'd prefer not to use "BETWEEN," rather, I want to pick and choose dates.
© Stack Overflow or respective owner