how to update existing date and insert new date in php MYSQL
<p>hello i have little problem in updating date</p>

<p>my first table is</p>

<pre><code>DONOR
donor-nic----username-----status
111----------ali----------available
222---------usman--------notavailable
</code></pre>

<p>my second table is</p>

<pre><code>DONATION
donation_id------donor_nic-----date---
1----------------111----------2012/03/04
2---------------111-----------2012/06/07
3----------------111---------2012/07/08
4----------------222---------2012/03/03
</code></pre>

<p>now i am editing profile like
change date:  2012/07/07
change status: available/not available</p>

<p>i want to do that.. if donor that is editing profile/status.. select the date that already exists in donation table with his donor_nic then it will update his date.. 
if donor select new date that does not exist in donation table then it will insert this date..</p>

<p>anyone plz help me.. i dunt knw how to select all the dates of donor (111)
and then match this date from the new date.. plzz helpp mee</p>
