Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Problem with local view
Message
From
29/05/2002 18:08:17
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Problem with local view
Miscellaneous
Thread ID:
00662776
Message ID:
00662776
Views:
40
Hi Ken,

How are you? I am good - very busy. I'm sorry I never followed up with you last time - a few weeks ago, when we exchanged emails. Anyway, I have a specific problem/question now with a local view. I posted a thread to ALL, but I thought I would post directly to you also, since I know that you are very knowledgable in the area of views.

Please let me know if a) you have the time available right now to help me and b)if you do have the time, let me know if it something that you can provide a 'quick answer to', or whether it is something that you will need to invest considerable time in, in which case I can consider how much billable time I can invest in it. Thanks.

Here is my problem:

I created a view, v_ordrfile, based upon a free table, ordrfile. I used the 'other' button in the view editor dialog box to specify the table and path. BTW, the ordrfile table is not in the same folder as my dbc.

Immediately after I created the view, I issued the command 'use v_ordrfile' from the command window. The view opened up. The I did some other operations (not sure what). Then I attempted the same command, 'use v_ordrfile'. However, this time, a dialog box came up, with a list of tables in the dbc, and an 'other' button. I chose the other button, and it let me choose my free table again. Thereafter, when I issued 'use v_ordrfile', I did not get the dialog box again.

It seems as if VFP was confused (or at least I am confused!) about what the path is to the free table. What property of dbgetprop()/setprop(), or cursorgetprop()/setprop() ?? can be queried/set regarding the path.

?dbgetprop('v_ordrfile','view','tables') returns 'ordrfile' with no path.

?dbgetprop('v_ordrfile','view','sql') returns a sql statement that has no path specified in the from clause, it is just 'from ordrfile'.

?cursorgetprop('sourcename','v_ordrfile') returns 'v_ordrfile'

I would think based upon the vfp help, that sourcename would have the full path to the table, but it doesn't.

The vfp help for cursorgetprop says:

Database C The name of the database in which the table or view is contained. If a table is a free table, contains the empty string.
Read-Only.

SourceName C Contains the long name for a SQL view or a table in a database, or the file path and table name for a free table.
Read-Only.

I am building this view in a test environment. I need to be able to change the path to the free table at runtime.

TIA
Next
Reply
Map
View

Click here to load this message in the networking platform