Question

I am using phpMyAdmin to create a table with information for a timetable.

Activity|Start|End|Day|Room

I am populating the table from a CSV file. When the schedule changes (adding new activity, time changes, etc) I want to import the CSV file again but have that replace all information stored in the table so that only the new Schedule information is stored.

In the Import section of phpMyAdmin I have the following settings

  • Format CSV
  • Replace table data with file
  • Columns separated with: ,
  • Columns enclosed with: "
  • Columns escaped with: /
  • Lines terminated with: auto

This just adds the new data to the table along with all the previous data. Is there a setting I am missing, or a Method I can use?

Thank you

Was it helpful?

Solution

Truncate & then load again!!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top