Jump to content

table data with updated timestamp


jd0000

Recommended Posts

I'm trying to create a table where I have information about a computer -- for example -- name, ip, memory, hd size. I scan client computers daily to get a report of their info which i put into a csv, then i run a script to convert that csv into SQL statements to update my database as needed. I want to only update rows where information has changed -- mainly because i need to have an "updated" timestamp on the table, so another script can look at the table and only select rows updated after timestamp XX.

 

The problem is, since I am just parsing a csv file to create the INSERTS, i dont know if the exact data already exists in the table. I could do it differently where I do selects for each set of computer data to see if its there, but with 2000+ computers, that would take forever.

 

Any suggestions on how to work this out?

 

Thanks!

 

 

Link to comment
https://forums.phpfreaks.com/topic/179361-table-data-with-updated-timestamp/
Share on other sites

Archived

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

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.