Delete record using SQL but shows deleted record only.

  • Thread starter Thread starter Jenny
  • Start date Start date
J

Jenny

Hi ,

I have a basic question about SQL.
I need to delete a record from customer list and the Syntax is as
below:

DELETE tblcustomer.* FROM tblcustomer
WHERE (((tblcustomer.Customer_Name)='ics'));

However, the result shows only one Deleted record "ICS".
Do I miss anything?
Thanks

Jenny
 
What were you expecting? Do you have other customer named ics?

Did you perhaps want to delete rows for any customer whose name started with
ics? If so, try:

DELETE tblcustomer.* FROM tblcustomer
WHERE (((tblcustomer.Customer_Name) LIKE 'ics*'));

If you wanted to delete rows for any customer who had ics anywhere in their
name, try:

DELETE tblcustomer.* FROM tblcustomer
WHERE (((tblcustomer.Customer_Name) LIKE '*ics*'));

If you're using ADO, and not DAO, replace the asterisks with percent signs:

DELETE tblcustomer.* FROM tblcustomer
WHERE (((tblcustomer.Customer_Name) LIKE 'ics%'));

or

DELETE tblcustomer.* FROM tblcustomer
WHERE (((tblcustomer.Customer_Name) LIKE '%ics%'));
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top