Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
View that references a view - parameterisation blues
Message
From
30/04/1998 07:13:51
 
 
To
30/04/1998 06:11:21
Steve Camsell
Windmill Associates
Bath, United Kingdom
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00095904
Message ID:
00095920
Views:
23
>I have a local view. This local view uses fields from a remote view. My remote view is parameterised to retrieve lines for a specified order. This works fine in isolation. I open the remote view using the NODATA clause in the DataEnv, then in the Init() of the form I retrieve the order id, then requery the view.
>
>The problem is, that even when I open my local view with the NODATA clause, Fox still prompts me for the value of nOrder_id (which is required by the remote view). Even when I do the following from the command line I get the problem:
>

>USE DBname!RemoteViewName NODATA &&-Parameterised
>USE DBname!LocalViewName NODATA &&-Not parameterised
>

>As soon as the second line is run it asks me for the order_id that the remote view needs to retieve order lines! Am I doing something wrong? Is this a bug? Is there a workaround?

when you open a view with no data VFP still opens it - it just uses some value that does not retrive any data
the problem when you use a parameter for the order is that it must be defined when you open a view - because if you substitute it with something meaningless
it you get an error

you can probably solve this by defining your parameter in the BeforeOpenTables event or only opening the view inside the form after you've defined the parameter


Arnon
Previous
Reply
Map
View

Click here to load this message in the networking platform