fmoore0001
asked on
Refresh a Cursor?
I often open several instances of the same table when I want to relate the table to a parent and be able to move the record pointer freely for a lookup. The problem is that if I append a new record in one cursor it is not immediately visible in the other cursor for the lookup. Is there a way to have a cursor refresh its data from disc periodically?
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
OK, now we understand changes may be visible after TABLEUPDATE().
BUT it is still not clear how your cursors are created. If they are just different aliases to one table then it should be sufficient to refresh appropriate controls where data are displayed.
If your cursors are created by some query which creates standalone table then you have to recreate such cursors.
Do decide which of above is valid you may issue LIST STATUS TO FILE YourFile.TXT and look at the file created.
BTW, one more thing is not so clear: Are you using same record of your Client table to store both lender and borrower? I would guess such data should be in different records.
BUT it is still not clear how your cursors are created. If they are just different aliases to one table then it should be sufficient to refresh appropriate controls where data are displayed.
If your cursors are created by some query which creates standalone table then you have to recreate such cursors.
Do decide which of above is valid you may issue LIST STATUS TO FILE YourFile.TXT and look at the file created.
BTW, one more thing is not so clear: Are you using same record of your Client table to store both lender and borrower? I would guess such data should be in different records.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks for the help, guys, The solution for us was a combination of things.
ASKER
We have a table called 'Client' which contains all types of client data, some lenders, some borrowers, some payables. In some cases we need lender, borrower and payable data at the same time. We do this by having three cursors in the data environment all based on the same table, 'Client', but with the record pointer on different records in each cursor. If I make a change to the cursor that represents the borrower those changes will not be visible in the cursor that represents the lender until I do a table update on the borrower cursor then close and reopen the lender cursor? Is there no other way to refresh the lender cursor without closing and reopening it?