문제

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

도움이 되었습니까?

해결책

Truncate & then load again!!

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top