Copying of records of open databases in style with pseudonym
Posted: Fri Aug 24, 2012 11:49 am
How to copy all records of one database in another if both of them are open (COPY FILE not to use) in style with pseudonyms? As in this style the functional analog of the program will look:
Something such as it?
The given option at compilation gives syntactic errors
Code: Select all
SELECT Abs
DBGOTOP()
DO WHILE .NOT. EOF()
Ar := {}
FOR j=1 TO FCOUNT()
AADD(Ar, FIELDGET(j))
NEXT
SELECT InfVisio
APPEND BLANK
FOR j=1 TO LEN(Ar)
FIELDPUT(j,Ar[j])
NEXT
SELECT Abs
DBSKIP(1)
ENDDO
Code: Select all
Abs->(DBGOTOP())
DO WHILE Abs->(.NOT. EOF())
FOR j=1 TO Abs->(FCOUNT())
InfVisio->(FIELDPUT(j,Abs->FIELDGET(j)))
NEXT
Abs->(DBSKIP(1))
ENDDO