Click here to Skip to main content
16,012,153 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
dear sir,

Example:
SQL
if exists (select * from table_name where key = @key)
begin
   update table set ...
   where key = @key
end
else
begin
   insert table (key, ...)
   values (@key, ...)
end


I want this query in LINQ concepts.
how to get code.


With Regrads
By mohan.
Posted
Updated 24-Nov-11 19:25pm
v2

1 solution

it's pretty easy can i have the data and i'll do it for you ..

here's the basics of linq.
http://www.deitel.com/ResourceCenters/Programming/MicrosoftLINQ/Tutorials/tabid/2673/Default.aspx[^]


hope it helps!
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900