Design Question

If you have questions or if you want to share your opinion about Aware IM post your message on this forum
Post Reply
ab042
Posts: 326
Joined: Mon Jul 17, 2006 4:11 am

Design Question

Post by ab042 »

I need to create a unique email database list and the data can come from several different places. How would you suggest I do it.

For Example: I have several Objects in several databases that may collect email addresses. I want to have ONE database to hold the Object for UniqueEMails. How can I link the different Objects to this ONE file?
aware_support2
Posts: 595
Joined: Sun Apr 24, 2005 2:22 am
Contact:

Post by aware_support2 »

If you mean data sources outside of Aware IM, you need to create an object in Aware IM and import the external data into that object. To ensure uniqueness of email address you can add a rule to that object, for example:

If EXISTS Contact WHERE (Contact.EmailAddress = ThisContact.EmailAddress AND Contact.ID <> ThisContact.ID)
Then REPORT ERROR 'Contact with this email address already exits.'

When you import data with Validation option enabled, Aware IM will reject records with duplicate email addresses.


If you mean objects of different types inside an Aware IM business space, like Client, Employee, Partner, etc. then you can do the following to ensure uniqueness of email address across instances of different objects. Define a business object group, say called Correspondent, make the objects with email addresses to be members of the group, and add a rule to each member object, for example to object Client:

If EXISTS Correspondent WHERE (Correspondent.EmailAddress = ThisClient.EmailAddress AND Correspondent.ID <> ThisClient.ID)
Then REPORT ERROR 'A correspondent with this email address already exits.'

With such an object group in place you can run a query to list all email addresses in the business space regardless of the actual object type to which the listed instances belong.
Aware IM Support Team
Post Reply