Click here to Skip to main content
15,891,567 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
hi
I want to save the details what i am giving through the textboxes(in my .aspx pages) to sqltables for this i create a storedprocedure like this
SQL
CREATE PROCEDURE INSERT_WEBSITEDETAILS
	@WebsiteName VARCHAR(100),
	@LiveIp1 NVARCHAR(100) ,
	@LiveIp2  NVARCHAR(100) ,
	@PortId   VARCHAR(100),	
	@ERROR VARCHAR(100) OUT
AS
BEGIN
SET NOCOUNT ON;
DECLARE @Createdate DATE
declare @Exist int
set @Exist = (SELECT count( PortId) FROM Websitedetails WHERE @PortId=PortId AND  @WebsiteName=WebsiteName)
if(@Exist=0)
BEGIN
	INSERT INTO Websitedetails 
	(WebsiteName,LiveIp1,LiveIp2,PortId,Createdate)
	VALUES
	(@WebsiteName,@LiveIp1,@LiveIp2,@PortId,GETDATE())
	SET @ERROR='UPDATED SUCCESSFULLY'
	END
	ELSE
	BEGIN
	SET @ERROR=' already exists'
	END	
END

BUT I DONT KNOW HOW TO CALL THIS STOREDPROCEDURE IN FRONTEND
plz help me
Posted
Updated 19-Mar-13 20:32pm
v2

use below links
Link1[^]
Link2[^]
 
Share this answer
 
Comments
Maciej Los 20-Mar-13 15:49pm    
+5!
 
Share this answer
 
Comments
Maciej Los 20-Mar-13 15:49pm    
+5!
Prasad_Kulkarni 21-Mar-13 1:49am    
Thank you Maciej Los!
 
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