Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Arggh Newbie can not get SP value back to VFP
Message
From
09/10/2003 10:48:26
 
 
To
All
General information
Forum:
Microsoft SQL Server
Category:
Other
Title:
Arggh Newbie can not get SP value back to VFP
Miscellaneous
Thread ID:
00836870
Message ID:
00836870
Views:
43
I just cant figure how to get the SP to return data to VFP

When I try to call the SP from VFP I get a -1 error returned
see below code for what I have tried
SET QUOTED_IDENTIFIER ON 
GO
SET ANSI_NULLS ON 
GO


ALTER   PROCEDURE sp_getpersonaldatastring

            @StrAppdi varchar(50)

AS


DECLARE @string varchar(4000)
SET @string = ''

SELECT @string = @string + CHAR(13) + dbo.DataClass.DataClassDesc
FROM  dbo.SysDataClass INNER JOIN
      dbo.DataClass ON dbo.SysDataClass.DataClassID = dbo.DataClass.DataClassID
WHERE (dbo.SysDataClass.SystemID = @StrAppdi)
ORDER BY dbo.SysDataClass.SystemID



return  @string



GO
SET QUOTED_IDENTIFIER OFF 
GO
SET ANSI_NULLS ON 
GO
I am trying to call the SP with a parameter of '421' and I want my conatenated string returning in lcRetval
and in VFP
lcretval=''
strAppid='421'

? SQLExec(lnHandle,"EXEC getpersonaldatastring ?@lcRetVal ?StrAppdi")
? SQLExec(lnHandle,"EXEC getpersonaldatastring '421'")

they both return -1 :(
Please just alter the SP for me so it works and give me the correct way to call it with a parameter from VFP before I go quite mad :(
Next
Reply
Map
View

Click here to load this message in the networking platform