Mass adding contact point purposes

Does anyone know how to mass add contact point purposes?  To do it individually seems like a giant undertaking that I would like to create a short cut to.  Any help is appreciated!

  • Former Member
    Former Member $organization

    We have a job set up to do this, the script is:

    insert into TX_CONTACT_POINT_PURPOSE

    (purpose_id, contact_point_id, contact_point_category, create_dt, create_loc, created_by, last_update_dt, last_updated_by)

    select

    21, -- ATTPAC Ack Letter

    addr.address_no, -- Contact Point ID

    -1, -- Postal Address

    GETDATE(),

    'SchedJob',

    'SchedJob',

    GETDATE(),

    'SchedJub'

    from

    T_ADDRESS as addr

    where

    addr.address_type = 69 -- ATTPAC Devo Address

    and -- Make sure record does not already exist

    not exists (

    SELECT

    0

    FROM TX_CONTACT_POINT_PURPOSE as cpp

    WHERE 

    cpp.contact_point_id = addr.address_no

    and 

    cpp.purpose_id = 21

    and

    cpp.contact_point_category = -1

    )

  • Thanks for sharing this!  Need to do some more testing, but looks like it's exactly what I needed!

    Kanani Reichlin

    Seattle Children's Theatre

  • I'm just jumping in on this existing thread.  Has anyone built a front end facing utility to allow users to mass add / delete Contact Point Purposes to email addresses on constituents?  Our DBA is currently handling this on the back-end and I've spec'd out requirements to build a utility for ongoing updates of the CPPs but would love hear if anyone has already done this and any possible challenges to watch out for...  

    Thanks,

    Chuck Buchanan / New York Philharmonic 

  • I haven't here mainly for data integrity reasons, but setting one up would not be too difficult. You would need to cascade your purpose parameters based on category before hand and then pass them on to an insert or delete.