I have a file with an id# and table id#.
I used seek to check if the id# is there. How do I get it to look at all instances of that id# and check if the table id# is there or not, and add if not?
You have lots of choices here. I'll assume you don't have an index tag on the combination of ID and TableID, but do have indexes on each of them separately. If so, your best bet is probably code like this:
Code:
SELECT YourTable
LOCATE FOR ID = m.nID and TableID = m.nTableID
IF NOT FOUND()
INSERT INTO YourTable ;
(ID, TableID) ;
VALUES (m.nID, m.nTableID)
ENDIF
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.