Olaf's and CaptainCyril's advice above is good.
However if you want to learn some more Foxpro, you might want to study the following (I hope there aren't too many typos in it...)
Dimension aryTbl1Flds (1)
USE Table1 IN 0
SELECT Table1
nFldCnt1 = AFIELDS(aryTbl1Flds) && Put list of field info into array - use AFIELDS()
nTbl1RecCount = RECCOUNT() && Get record count
Dimension aryTbl2Flds (1)
USE Table2 IN 0
SELECT Table2
nFldCnt2 = =AFIELDS(aryTbl2Flds)
nTbl2RecCount = RECCOUNT()
lTablesSame = .T. && Start Off Assuming Tables Are SAME
* --- Check If Field Count Is Same ---
IF nFldCnt1 = nFldCnt2
* --- Number of Fields Same, Now Check Each Field's Name,Type,Size, etc ---
FOR Cntr = 1 TO nFldCnt1
IF aryTbl1Flds(Cntr) # aryTbl2Flds(Cntr)
* --- Field Type,Size, etc. Different - TABLES NOT SAME ---
lTablesSame = .F.
EXIT
ENDIF
ENDFOR
ELSE
* --- Field Count D ifferent - TABLES NOT SAME ---
lTablesSame = .F.
ENDIF
IF lTablesSame
* --- Table Field Parameters SAME, Now check field contents ---
IF nTbl1RecCount = nTbl2RecCount
* --- Same Number of Records In Both Tables ---
SELECT Table1
SCAN
nRecno = RECNO
* --- Check Each Field Value For This Record In Both Tables ---
FOR FldCntr = 1 TO nFldCnt1
cFldName = aryTbl1Flds(FldCntr,1) && Get Field Name
Value1 = EVAL(cFldName) & Get Field Value
SELECT Table2
GO nRecno
Value2 = EVAL(cFldName)
IF Value1 # Value2
* --- Field Value In Table1 NOT EQUAL TO Field Value in Table 2 ---
lTablesSame = .F.
EXIT
ENDIF
ENDFOR
SELECT Table1
ENDSCAN
ELSE
* --- Record Count Different - TABLES NOT SAME ---
lTablesSame = .F.
ENDIF
ENDIF
* --- I'll skip checking Table Indicies at this time ---
IF NOT lTablesSame
WAIT WINDOW "Tables NOT SAME! "
ENDIF
Good Luck