Given
How do I check the RETURN value
I have tried
SqldataSet1 is a TSQLDataSet with CommandType ctStoredProc.
Thanks,
Code:
set ANSI_NULLS OFF
set QUOTED_IDENTIFIER ON
GO
ALTER procedure [dbo].[sp_DiaryShow] @mySalesDesk varchar(50)
AS
declare @iCount int
select @iCount = count(*) from boss_system
where Parameter ='DiaryNotAllowed'
and value = @mySalesDesk
IF @iCount >= 1 /* not allowed to see diary */
RETURN 0
else /* can see diary options */
RETURN 1
How do I check the RETURN value
I have tried
Code:
procedure TForm1.Button1Click(Sender: TObject);
Var
retVal: integer;
begin
with SQLDataSet1 do
begin
parambyname('@mySalesDesk').asstring :='BIF Direct Apps Dub';
RetVal := execSQL;
ShowMessage(IntToStr(RetVal));
end;
end;
SqldataSet1 is a TSQLDataSet with CommandType ctStoredProc.
Thanks,