ACCESS STORED PROBLEM

S

Savas Ates

this one doesnt work
if i cancel line which starts with --if not -- it works? why ? dont i
use --if not-- clause

CREATE PROCEDURE ST_ADDTOBASKET

(
@PSesID char (75),

@PProductID integer ,

@PQuantity integer
)
AS

IF NOT EXISTS (SELECT 1 FROM BASKET WHERE (sesid=@PSesID and
productid=@PProductID))
INSERT INTO BASKET (sesid,productid,quantity) VALUES
(@PSesID,@PProductID,@PQuantity)
 
J

JohnFol

Hi Savas, this looks like a SQL stored procedure. Might be worth posting to
a SQL group.
 
Top