http://www.belajarsqlserver.com/2015/10/sql-server-store-procedure.html
=======================================
CREATE PROCEDURE say_holaa
AS
BEGIN
print'HOLAAA12345'
END
GO
--EXEC say_holaa
=======================================
CREATE PROCEDURE PAKE_PARAM
(
@PARAM1 VARCHAR(64),
@PARAM2 INT
)
AS
BEGIN
PRINT 'NAMA U:'+@PARAM1
PRINT 'ANTRIAN KE:'+cast(@param2 as varchar)
END
--EXEC PAKE_PARAM'tukinem','31'
======================================
create procedure insert_pelanggan
(
@nama nchar(10),
@alamat nchar(50)
)
as
begin
insert into Pelanggan values(@nama, @alamat)
select * from Pelanggan
end
--exec insert_pelanggan'susi','solo'
Langganan:
Posting Komentar (Atom)
0 Response to "belajar store prosedure"
Posting Komentar