Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

search for & delete a blank record

Status
Not open for further replies.

Anjilique

Programmer
Mar 10, 2003
2
CA
A user is somehow populating a table with a blank record (i can't recreate the error) so what I'm trying to do is check for the blank record and delete it by code.

Any ideas on how to do this?

Anji
 
This is an example query that will delete any record from my Archive table where the person's name is blank...


DELETE Archive.*, Archive.LastName, Archive.FirstName
FROM Archive
WHERE (((Archive.LastName)=null) AND ((Archive.FirstName)=null));

Hope this helps you...

--James
junior1544@jmjpc.net
Life is change. To deny change is to deny life.
 
Hi...
thanks for your reply.. I did figure it out eventually and used embedded sql to find the blank row and then used and EOF check to make sure it wasn't the blank row at the end of the table. Once that was done, I did another SQL query to delete the said row and had the database execute the query.

All's well that end's well. :)

A.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top