Jump to content
Sign in to follow this  
naag

displaying data from sql using C# with asp.net

Recommended Posts

hello...

 

 

I have written a stored procedure to get a column Named as "Name" from the table DN_Software.The query is "Select Name From DN_Software Where DN_DiscoverHostID=5" for Particular ID. Now i want to display that list of names in front end page. please help me how to display using that stored procedure using asp.net displaying in c#.please...

 

 

"ALTER PROCEDURE [dbo].[DN_Software_Read_Distinct_Name_By_DiscoveredHostID](

@Active [int],
@DN_DiscoveredHostID Int)
AS
SELECT DISTINCT Name FROM DN_Software where DN_DiscoveredHostID = @DN_DiscoveredHostID
--EXEC DN_Software_Read_Distinct_Name_By_DiscoveredHostID @Active = 1, @DN_DiscoveredHostID = 5"
--------------this my stored procedure.

Share this post


Link to post
Share on other sites

Which part are you having problems with? Are you connecting to the database and running queries? You would execute a stored procedure the same way as another query, the syntax for the query is just slightly different.

Share this post


Link to post
Share on other sites

thankz for ur reply ....problem is to get the data from the stored procedure....sql connection is proper but im enable to get the data using stored procedure....???!!!

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...