Delete Rows from an Access Table
- Last UpdatedSep 16, 2025
- 1 minute read
The DELETE keyword is used with a WHERE clause to delete the necessary row or rows. If the WHERE clause is not based on a primary key, more than one record may be deleted.
Function SQLDelete
INT hSQL, iResult;
hSQL = SQLConnect("DSN=ODBCTest;UID=YourUID_C;PWD=YourPWD");
IF hSQL <> -1 Then
iResult = SQLExec(hSQL, "DELETE FROM tblRecipes WHERE
Recipe = 'X1234'");
SQLDisconnect(hSQL);
END
END