Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Views and deleted records
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00194164
Message ID:
00194532
Views:
15
>>I will try this, but the monkey wrench in this is that I use the view designer in the database to create and maintain my views. You have the statment DELETED() as deleted, how can this be accomplished using the view designer versus creating it on the fly. I can get around this but I am just curious. I will test you steps shortly.
>
>
>Not to hard... when you are in the View designer, on the Fields tab, at the bottom of the field list is a text box labeled 'Functions and expressions:'.
>
>Just type
>
>deleted() as deleted
>
>into that text box, and press the ADD button.
>
>BOb

Well guess what, another problem, feature, bug, stupidity on my part, I dont know. But the SQL Select statement created for me in the view designer is:

SELECT Docacmds.docnumber, Dmaacmds.dmarev, Dmaacmds_a.dmarev,;
Adnacmds.adnaprdate, Adnacmds.adnaprsign, Adnacmds.adnodmakey,;
Adnacmds.adnndmakey, DELETED("adnacmds") AS adndeleted;
FROM acmds!dmaacmds, acmds!docacmds, acmds!resacmds, acmds!adnacmds,;
acmds!dstacmds, acmds!dmaacmds Dmaacmds_a, acmds!docacmds Docacmds_a;
WHERE Adnacmds.adnndmakey = ?vp_adnndmakey;
AND Adnacmds.adnodmakey = Dmaacmds.dmakey;
AND Dmaacmds.dmadockey = Docacmds.dockey;
AND Docacmds.docreskey = Resacmds.reskey;
AND Dmaacmds.dmadstkey = Dstacmds.dstkey;
AND Adnacmds.adnndmakey = Dmaacmds_a.dmakey;
AND Dmaacmds_a.dmadockey = Docacmds_a.dockey

As you can see I have the adndeleted set above, but when I run the query one time the query tells me adndeleted = .T., I then close my tables and open the view, requery() giving the same parameter and I get adndeleted = .F. I have not changed anything in the local table, I am just requering the view after opening and closing it. I get the one record everytime I run the query, so I know the data the view is giving me is correct, but the adndeleted flag is coming back wrong on several of my requeries. Any ideas..
Bret Hobbs

"We'd have been called juvenile delinquents only our neighborhood couldn't afford a sociologist." Bob Hope
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform