CREATE FUNCTION IntegerIncrement (@integerVal int)
RETURNS int AS
BEGIN
SET @integerVal = @integerVal + 1
RETURN @integerVal
END
GO
In Delphi, have an ADODataSet with CommandType = cmdText, and the
CommandText set to
SELECT dbo.IntegerIncrement(:SomeInt) AS SomeAnswer
Manually add a parameter into the dataset's parameter list, setting the
properties as follows
Name = 'SomeInt', Attributes = [paSigned], DataType = ftInteger, Precision =
10, Size = 4, Value = Null
Execute the select statement as normal e.g.
ADODataSet1.Parameters.ParamByName('SomeInt').Value := 1;
ADODataSet1.Open;
Regards,
Andy Mackie.
Keith Marbach <kmar...@zunna.com> wrote in message news:3b968cd5_2@dnews...
"Andy Mackie" <ama...@citynetworks.co.uk> wrote in message
news:3b97387b$1_1@dnews...
> Thanks Andy. That's very helpful.
I'd appreciate it if you'd edit down your quotes a little. Thanks.
-- Barry