Who we are

What we can do for you

Case sudies

Our philosophy

About CRM

News & Tech Blog

Follow our news:

Follow canonburysvcs on Twitter Follow Canonbury Services on Facebook Follow Canonbury Services on RSS Follow Canonbury Services on Atom

NEWS & TECH BLOG

Earlier >

How to identify primary email addresses

20/01/12

Categories: GoldMine, SQL

It's easy enough to write a query to find email address records in GoldMine. This simple one does the job:

select * from contsupp where contact='e-mail address'

However, if we want to limit the results to just primary addresses then we also need to look at the flags that are held in the Zip field. A '1' in the second position is the marker that we are looking for and so we can use SQL's single-character wildcard (an underscore) to find that:

select * from contsupp where contact='e-mail address' and contsupp.zip like '_1__'