如果你想查询所有KM开头的字段的话: LOCAL liI as Integer, lcFieldName as Character, lcFieldList as CharacterlcFieldList = "" FOR liI = 1 TO FCOUNT( "CJK" )
lcFieldName = FIELD( liI, "CJK" )
IF LOWER( LEFT( lcFieldName, 2 ) ) = "km"
lcFieldList = lcFieldList + ", " + lcFieldName
ENDIF
ENDFOR IF ! EMPTY( lcFieldList )
lcFieldList = SUBSTR( lcFieldList, 3 )
SELECT &lcFieldList. FROM cjk
ENDIF 只要修改 IF LOWER( LEFT( lcFieldName, 2 ) ) = "km" 这句,就可以查询其它类型的相似字段了