Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Local Views
Message
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00141438
Message ID:
00141484
Views:
20
>Hi all!
>
>Can anyone explain briefly what a local view is best used for and what is best used (query, table, view) in a form cmdbtn to send a SQL-Select statement to a report form when useing inner-joins between 3 tables?
>
>TIA
>
>Dan

I always prefer to use SELECT... INTO CURSOR to prepare the cursor for the report, and rarely use the Report DataEnvironment. This way I keep everyting regarding the report in one place (report and SELECT may use local variables defined in this cmdPrint.Click() method). IMHO, if the view is used just for the report, the SELECT statement in cmdPrint.Click() is better because it does not increase DBC size and cannot be corrupted in DBC.
Also, if you have 2 parallel joins from one table the View Designer will not allow you to create such a view (you still can create it programmatically, but keep in mind to not open it in VD :), so anyway you need to save the copy of that SQL in a safe place - why not in the cmdPrint.Click() :)

Nick
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Previous
Reply
Map
View

Click here to load this message in the networking platform