Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

How can I Delete Creditcard Numbers


jarvoid

Recommended Posts

I had an OSCommerce site for an event a couple months ago. The event is over and I would like to delete the creditcard numbers from my database. My host has PhPmyAdmin but I can not figure out how to delete the values in the CC_Numbers field and leave everything else intact. I can edit each entry manually but don't really want to do this for a couple hundred order.

 

I suppose I could download (export) the database then upload (import) after editting it. Would this work? It seems there should be a better way to do it.

 

What would be ideal is if I had an SQL script that would delete the credit card numbers associated with orders more than 90 days old. Would there be a problem if the same customer and number was used on multiple orders?

 

Thanks,

Jarvis

Link to comment
Share on other sites

UPDATE `orders` SET cc_number = '' WHERE  date_purchased <= DATE_SUB(now(), INTERVAL 90 DAYS);

 

(untested - backup before using - just incase!)

 

Note: Unless you are PCI DSS compliant it will be in breach of the Visa / Mastercard rules to store credit card details in any form and leave yourself liable to huge fines

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...