Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Strange problem
Message
 
 
À
12/03/2012 19:32:58
James Blackburn
Qualty Design Systems, Inc.
Kuna, Idaho, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire d'écran & Écrans
Titre:
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Divers
Thread ID:
01538139
Message ID:
01538154
Vues:
58
I'll try this, but I believe we can not mix named and non-named parameters.

>I will admit that I am a lot more familiar with Sql Anywhere then Sql Server but I would call the sp this way
>=mySQLExec("execute dbo.siriussp_rsGetBlocks @TemplateID = ?m.nTemplateID,?@nBlockCount, ?@nSeatsCount , 'rsTSBlocks'",program())
>
>Seems to me that if you pass a variable by reference then the value would be returned by the SP. I thought "output" was part of the parameter statement of the SP. Anyway, the above is how I would do this is Sql Anywhere.
>
>>>Hi everybody,
>>>
>>>I got a very puzzling problem. I have a form which I've been testing a lot and I haven't changed this particular piece of code for a long time. Today this code gives me an ODBC error (incorrect code near OUTPUT) and it worked fine just a few days ago (last time I tested it). I checked both compiled version and in IDE and both produced the same error.
>>>
>>>
>>>private nTemplateID, nBlockCount, nSeatsCount
>>>      nBlockCount = 0
>>>      nSeatsCount = 0
>>>      nTemplateID = thisform.oCurrentNode.values("TemplateID").value
>>>      =mySQLExec("execute dbo.siriussp_rsGetBlocks @TemplateID = ?m.nTemplateID, @BlocksCount = ?@nBlockCount OUTPUT, @SeatsCount = ?@nSeatsCount OUTPUT" , 'rsTSBlocks',program())
>>>
>>>
>>>What may be the issue here? I want to get back 2 parameters values.
>>>
>>>Thanks a lot in advance.
>>
>>This is what I see in profiler:
>>
>>set @p4=0
>>declare @p5 float
>>set @p5=0
>>exec sp_executesql N'-- NAOMIN/ADMIN sysmanager:rsvenueconfigure.sct:venueconfiguration.venuestree.itemactivate:77
>>
>>execute dbo.siriussp_rsGetBlocks @TemplateID = @P1 , @BlocksCount = @P2 OUTPUT  OUTPUT, @SeatsCount = @P3 OUTPUT  OUTPUT',N'@P1 float,@P2 float OUTPUT,@P3 float OUTPUT',1,@p4 output,@p5 output
>>select @p4, @p5
>>
>>Why do I get OUTPUT doubled? Any why the parameters get passed as float?
>>
>>I'll try re-booting my PC as our tester didn't get the same issue on the exact same version I tried also.
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform