Click here to Skip to main content
16,004,901 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: getting textbox text from client back to server side Pin
marky77719-Feb-09 20:39
marky77719-Feb-09 20:39 
AnswerRe: getting textbox text from client back to server side Pin
Mark Graham19-Feb-09 4:32
Mark Graham19-Feb-09 4:32 
GeneralRe: getting textbox text from client back to server side Pin
marky77719-Feb-09 21:23
marky77719-Feb-09 21:23 
QuestionError : Databinding methods such as Eval(), XPath(), and Bind() can only be used in the context of a databound control. Pin
Amol12345519-Feb-09 2:44
Amol12345519-Feb-09 2:44 
Questionhow can pictures and video store in data base? Pin
ali2k619-Feb-09 2:25
ali2k619-Feb-09 2:25 
Questionproblem in transaction . Pin
souravghosh1819-Feb-09 1:41
souravghosh1819-Feb-09 1:41 
AnswerRe: problem in transaction . Pin
Mark Graham19-Feb-09 4:43
Mark Graham19-Feb-09 4:43 
QuestionDal Exception Pin
Mogaambo19-Feb-09 1:25
Mogaambo19-Feb-09 1:25 
Hi iam working in a project, this is one of my stored procedure which neither allows you to insert duplicate vendor, nor either duplicate email.

but i am wondering whether this is the correct method of doing validation or i create 2 more store procedures 1 for checking duplicate vendor names another for duplicate email and 1 for insertion of vendor record.


ALTER PROCEDURE [dbo].[InsertVendorDetails]
-- Add the parameters for the stored procedure here
(
@strVendorName varchar(50),
@strPrim_Con varchar(12),
@strSec_Con varchar(12),
@strEmail varchar(50)=null,
@strAdd varchar(500),
@result Int output
)
AS
BEGIN


If Exists( Select Vendor_Name from Vendor where Vendor_Name=@strVendorName)
Begin
set @result = 2
End
Else
Begin
If Not Exists(Select email from Vendor where email=@strEmail and email is not null)
Begin
INSERT INTO VENDOR(VENDOR_NAME,PRIM_CONT_NO,SEC_CONT_NO,EMAIL,[ADDRESS])
VALUES(@strVendorName, @strPrim_Con, @strSec_Con, @strEmail, @strAdd )
set @result=@@Rowcount
End
Else
Begin
set @result = 3
End

End



END

“You will never be a leader unless you first learn to follow and be led.”
–Tiorio

"Coming together is a beginning, staying together is progress, and working together is success." Henry Ford

AnswerRe: Dal Exception Pin
Vimalsoft(Pty) Ltd19-Feb-09 3:52
professionalVimalsoft(Pty) Ltd19-Feb-09 3:52 
QuestionBase64 Decoding for Thermal Printer [modified] Pin
premchand197519-Feb-09 1:25
premchand197519-Feb-09 1:25 
QuestionModal popup Pin
krishna2gubbala19-Feb-09 0:21
krishna2gubbala19-Feb-09 0:21 
AnswerRe: Modal popup Pin
Calin Tatar19-Feb-09 2:32
Calin Tatar19-Feb-09 2:32 
AnswerRe: Modal popup Pin
Mark Graham19-Feb-09 4:22
Mark Graham19-Feb-09 4:22 
Questionpassing values from aspx page to htm page Pin
venu65619-Feb-09 0:13
venu65619-Feb-09 0:13 
AnswerRe: passing values from aspx page to htm page Pin
Greg Chelstowski19-Feb-09 0:39
Greg Chelstowski19-Feb-09 0:39 
GeneralRe: passing values from aspx page to htm page Pin
venu65619-Feb-09 0:59
venu65619-Feb-09 0:59 
GeneralRe: passing values from aspx page to htm page Pin
Greg Chelstowski19-Feb-09 1:03
Greg Chelstowski19-Feb-09 1:03 
GeneralRe: passing values from aspx page to htm page Pin
venu65619-Feb-09 1:10
venu65619-Feb-09 1:10 
QuestionProblem With dropdownlist. Pin
Deepak Nigam18-Feb-09 23:49
Deepak Nigam18-Feb-09 23:49 
QuestionServer time and local time Pin
yesu prakash18-Feb-09 23:40
yesu prakash18-Feb-09 23:40 
AnswerRe: Server time and local time Pin
keyur satyadev19-Feb-09 3:07
keyur satyadev19-Feb-09 3:07 
GeneralRe: Server time and local time Pin
yesu prakash19-Feb-09 17:40
yesu prakash19-Feb-09 17:40 
AnswerRe: Server time and local time Pin
Rajesh Chinnam21-Jun-09 23:52
Rajesh Chinnam21-Jun-09 23:52 
QuestionDLL Pin
Elango N18-Feb-09 22:55
Elango N18-Feb-09 22:55 
AnswerRe: DLL Pin
Christian Graus18-Feb-09 22:58
protectorChristian Graus18-Feb-09 22:58 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.