A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook - General Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Advanced Filters / SQL of Contact Records



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old January 16th 07, 04:03 PM posted to microsoft.public.outlook
Ralph Bender, MBA
external usenet poster
 
Posts: 1
Default Advanced Filters / SQL of Contact Records

I use Outlook 2003 to mail merge my electronic newsletter. Until recently,
we used a category tag (Newsletter) to sift through the contacts and give me
the records to use. Unfortunately, the categories field got corrupted
(erased) and we didn't discover the problem until after an automated
backup/archive subsequently archived the corrupted data.

So, what I decided to do was send it to everyone in my database and then
build a filter to eliminate those records that shouldn't get it. I did have
the sense over the years to include the word "Remove" in the notes field as
well as in the category field, so there's some restriction on the people
who's email I want to keep, but that don't want my newsletter.

My problem is that I've been unable to get the SQL code right. The following
code should not allow any record to show that doesn't meet these criterion:
1. has email address
2. does not have word "remove" in either the notes field nor in the
categories
3. does not have the category "business"

("DAV:isfolder" = false AND "DAV:ishidden" = false) AND
((NOT("http://schemas.microsoft.com/mapi/id/{00062004-0000-0000-C000-000000000046}/8084001f"
IS NULL) AND ("urn:schemas-microsoft-comfficeffice#Keywords" 'Remove'
OR "urn:schemas-microsoft-comfficeffice#Keywords" 'Business') AND
"urn:schemas:httpmail:textdescription" 'Remove'))

Unfortunately, it currently lets business records through the filter.

Thanks,
Ralph


Ads
  #2  
Old January 21st 07, 10:58 PM posted to microsoft.public.outlook
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default Advanced Filters / SQL of Contact Records

AND your two keywords criteria instead of ORing them.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003
http://www.turtleflock.com/olconfig/index.htm
and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
http://www.outlookcode.com/jumpstart.aspx

"Ralph Bender, MBA" wrote in message ...
I use Outlook 2003 to mail merge my electronic newsletter. Until recently,
we used a category tag (Newsletter) to sift through the contacts and give me
the records to use. Unfortunately, the categories field got corrupted
(erased) and we didn't discover the problem until after an automated
backup/archive subsequently archived the corrupted data.

So, what I decided to do was send it to everyone in my database and then
build a filter to eliminate those records that shouldn't get it. I did have
the sense over the years to include the word "Remove" in the notes field as
well as in the category field, so there's some restriction on the people
who's email I want to keep, but that don't want my newsletter.

My problem is that I've been unable to get the SQL code right. The following
code should not allow any record to show that doesn't meet these criterion:
1. has email address
2. does not have word "remove" in either the notes field nor in the
categories
3. does not have the category "business"

("DAV:isfolder" = false AND "DAV:ishidden" = false) AND
((NOT("http://schemas.microsoft.com/mapi/id/{00062004-0000-0000-C000-000000000046}/8084001f"
IS NULL) AND ("urn:schemas-microsoft-comfficeffice#Keywords" 'Remove'
OR "urn:schemas-microsoft-comfficeffice#Keywords" 'Business') AND
"urn:schemas:httpmail:textdescription" 'Remove'))

Unfortunately, it currently lets business records through the filter.

Thanks,
Ralph


 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Making individual contact records private RD Outlook - Using Contacts 1 December 1st 06 06:45 PM
Build 8036 appears to break some advanced filters Charles Belov Outlook - General Queries 3 September 25th 06 06:23 PM
how do I easily delete duplicate contact records phil Outlook - Using Contacts 1 July 7th 06 10:33 PM
Task filters should be linked to calendar filters fetch98 Outlook - Calandaring 0 January 19th 06 08:06 PM
Custom View Filters - Advanced deandepetra Outlook - Using Contacts 1 January 18th 06 10:15 AM


All times are GMT +1. The time now is 03:37 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.