>>>lcSourceFile = "C:\projects\FRS\FRS5Data.accdb" >>>pnConnHandle = SQLSTRINGCONNECT("Driver={Microsoft Access Driver (*.mdb, *.accdb)};DBQ=" + ; >>> lcSourceFile) >>>TEXT TO lcSQLCommand NOSHOW >>>INSERT INTO [TblHousehold] (SYSTEMPROGRAMCD, PROGRAMCD,LSTUPDTDTTM) VALUES (?m.sysprogcd,?m.programcd,?m.lstupdtdttm) >>>ENDTEXT >>> >>>lnResult = SQLEXEC(pnConnHandle,lcSQLCommand) >>>>But this below blows up with an error "Connectivity error: etc. Too few parameters. Expected 1."
>TEXT TO lcSQLCommand TEXTMERGE NOSHOW >INSERT INTO [tblHouseholdMember] (HOUSEHOLDSEQNBR,HOUSEHOLDVERSIONNBR,PERSONSEQNBR,LASTNAME) VALUES (<<lnHouseholdSeqNbr&rt&rt, <<lnHouseholdVersionNbr&rt&rt, <<lnPersonSeqNbr&rt&rt,<<m.lastname&rt&rt) >ENDTEXT >>Where the contents of the Watch window for lcSQLCommand after the Text Merge are
>"INSERT INTO [tblHouseholdMember] (HOUSEHOLDSEQNBR,HOUSEHOLDVERSIONNBR,PERSONSEQNBR,LASTNAME) VALUES (893, 1, 1,Kinch )"
>So what the heck is up with that?<<>>instead of & macros. Anyway, you're missing quotes around the last value, which is clearly a name field.