Sabtu, 27 Februari 2021

Re: [MSAccessProfessionals] Type Mismatch Run-time error ...Tired of this issue...

Yes, Option Explit placed.

On Sunday, February 28, 2021, 09:24:33 AM GMT+3, SAYYED ASHFAQUE HUSSAIN via groups.io <ashfaque_online=yahoo.com@groups.io> wrote:


Thanks Duane Hookom,

The debug print is giving following result:

DELETE * FROM T_EmpOTFooter WHERE OTID= 3 And Verified = 0

It means he is not picking up Verified field data. For this main record # 3, there are 5 footer records out of which 2 are unchecked so I  need them to delete from footer tbl and keep rest 3 saved.

And when it is reaching to execute below:
CurrentDb.Execute strSql, dbFailOnError
It produces Run-time error 3622
"You must use the dbSeeChanges option with OpenRecordset when accessing a SQL Server table that has an Identity Column.

When I tried with below:
 strSql = "DELETE * FROM T_EmpOTFooter WHERE OTID= " & Forms!F_EmpOTHeader!OTID & " And Verified = 0 dbSeeChanges"

Syntax error - Missing Operator

Please advise...

Tidak ada komentar:

Posting Komentar