I am trying to run a query on a bunch of tables and any values I get from any table I want to put in a seperate table.
schdDate = LEFT(STRTRAN(DTOC(DATE()), "/", ""), 4)
schdDate = INPUTBOX("Enter Date:", "Enter last four digits on schedule: ", schdDate, 15000)
file_count = ALLTRIM(str(ADIR(myArray, "K:\xxx\newm\mailfile\*"+ALLT(schdDate)+"j.dbf")))
file_count=VAL(file_count)
?file_count
CLEAR
FOR nCount = 1 TO file_count
myfile = "xx/xx" + myArray(nCount,1)
?myfile
SELECT * from &myfile WHERE xxxx AND xxx" AND INTO dbf
xxxx.dbf
but the problem is that since it is in a loop it simply overwrites whatever results it had before. Any suggestions?
schdDate = LEFT(STRTRAN(DTOC(DATE()), "/", ""), 4)
schdDate = INPUTBOX("Enter Date:", "Enter last four digits on schedule: ", schdDate, 15000)
file_count = ALLTRIM(str(ADIR(myArray, "K:\xxx\newm\mailfile\*"+ALLT(schdDate)+"j.dbf")))
file_count=VAL(file_count)
?file_count
CLEAR
FOR nCount = 1 TO file_count
myfile = "xx/xx" + myArray(nCount,1)
?myfile
SELECT * from &myfile WHERE xxxx AND xxx" AND INTO dbf
xxxx.dbf
but the problem is that since it is in a loop it simply overwrites whatever results it had before. Any suggestions?