| |
|
These are some of the frequently used SQL
queries for GoldMine. |
|
|
|
|
Contacts with Email address |
|
|
select contact,company from contact1
where accountno in
(select accountno from contsupp
where contact like 'E-mail Address')
order by contact |
|
|
|
|
Contacts with no Email address |
|
|
select contact,company from contact1
where accountno not in
(select accountno from contsupp
where contact like 'E-mail Address')
order by contact |
|
|
|
|
Email addresses for Primary and
Additional Contacts |
|
|
select contact1.company,contact1.contact,
contsupp.address2 as EM_Contact,
contsupp.contsupref,
contsupp.zip from contsupp join contact1
on contact1.accountno=contsupp.accountno and
contsupp.contact = 'E-mail Address'
order by contact1.company |
|
|
|
| Contacts
with Email addresses from a GoldMine group |
| |
Select
Accountno,ref from contgrps where userid =(
select recid from contgrps where ref = '<Group Name>') and accountno in
(Select Accountno from Contsupp where contact = 'E-mail Address') |
|
| |
| Contacts
without Email addresses from a GoldMine group |
| |
Select
Accountno,ref from contgrps where userid =(
select recid from contgrps where ref = ''<Group Name>') and accountno
not in
(Select Accountno from Contsupp where contact = 'E-mail Address') |
|
| |
| Today's
completed activities for all users |
| |
select * from
conthist where
day(ondate) = day(getdate()) and
month(ondate) = month(getdate()) and
year(ondate)=year(getdate()) |
|
| |
| |
|
|
| |