How to remove duplicate records of memo field

alap43841

Registered User.
Local time
Today, 11:06
Joined
May 9, 2006
Messages
36
I download a text file from the net that has 7 days news and every time the file is updated whenever there are some new news, but it contains only 7 days news. I need to download the file every day whenever new data is added and put it the MS Access database table where "Symbol", "News" and "PostingDate" are the three fields. I am facing problem in deleting duplicate records of memo field........ Let me be little more clear, say I have downloaded and imported the data on 1200 hours 31/3/2011 and again I want download and import new data at 2000 hours on the same day (31/3/2011) but I only want to add the new data> I tried to do this by SQL statement SELECT DISTINCT......but it does not allow to be executed on memo field. Also there might be same news on same Symbol in different date so I need to get the unique data basing on all three fields. I am attaching the DB here with. I have very shallow knowledge on VBA, please help me considering my limited knowledge on VBA .................thanks
 

Attachments

You are going to be struggling here because of the memo field. Can't think of a usable solution at the moment. Sorry.
 
Hi there,
do you want to remove(delete) duplicate records or select distinct records based on the News field? For selecting distinct records, you can try a query like:
Code:
[COLOR=Blue]SELECT DISTINCT TRIM[/COLOR](table_name.News) [COLOR=Blue]FROM[/COLOR] table_name;
where table_name is your table. As for distinguishing by date, you can extend the date of news to include the time of day when saving data into your table so that different news items on the same day can be differentiated; see NOW() intrinsic function. I hope this will be of help, bye.;)
 

Users who are viewing this thread

Back
Top Bottom