Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Stored procedure
Message
From
07/09/2004 20:41:02
 
 
To
07/09/2004 20:27:08
Cindy Winegarden
Duke University Medical Center
Durham, North Carolina, United States
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00940107
Message ID:
00940148
Views:
17
Hi Cindy

Yes, I was just saying that to Himlar. I had tried to circumvent this by the following
SELECT STR(newid('CUSTPAYMENT'),15) as cId FROM wotscont
which theoretically should give it the size. Note also that I am not even using the same table here. When I run this my counter jumps 3 at a time. This is somewhat mystifying but by putting a trace on I can see that two temporary cursors are created.

Do you know how I can create a view that returns a result from a stored procedure. this is basically what I am trying to do.

regards
Geoff Scott


>>Hi Hilmar
>>
>>
SELECT IIF(not table='CUSTPAYMENT',999999999999,newid('CUSTPAYMENT')) as nextid ;
>>	FROM ids WHERE table='CUSTPAYMENT' INTO CURSOR tNextId
>>
>>
>>executes the stored procedure twice even though there is only one record in with table='CUSTPAYMENT'
>
>Hi Geoff,
>
>The stored procedure runs at least twice. The first time around is to determine the maximum size of the resulting value so the column definition will be big enough for the whole value, and the following time(2) is when the SQL statement runs against the data.
May all your weeds be wildflowers
Previous
Reply
Map
View

Click here to load this message in the networking platform