CUB Constituent lookup not loading extension data
Hi all,
I made several extensions for CUB – Multiple Ethnicities, Religion Code, and a DNE Reason Code for the Email Addresses collection. The add, edit, and commit functionality works fine for all of them.
However, when I create a new batch with these extensions and search/select a Constituent in a row, all the fields in that row will pre-load with the appropriate data, except the extension fields.
Is this by design, or am I missing something?
Does the Constituent lookup and preload not include extensions?
Cheers!
-Willem
Comments
-
I think the solution would be to add an EditRow to the CommitRow section below the add row. With an Upsert batch like the CUB when you enter a constituent it actually switches to another form. This can be seen if you go to the CUB batch type page and look at the XML. The CUB will pass a PRIMARYRECORDID guid to the load/save implementations that you can use to load the existing extended data. This section of the documentation shows some more detail on batches like the CUB with some of the properties that make it different than a normal batch. Hope this helps!
0 -
All of the batch pieces are in place and functioning.
This is not related to the commit, though.
When a new batch is created, the UI opens the batch for row addition.
The moment you click on a row to add data, that row is created but not present in the batch table yet. When you search/select a Constituent, the row is populated with data for that constituent (just not the extension fields).
This all happens long before the commit state.
The edit function of the commit section handles rows from the batch for which the constituent already exists in the database – hence the database record is updated instead of having a new constituent inserted.
All the code for the batch extension I made can be found here, in an answer to a question about how to add a Do Not Email Reason Code to CUB:
But I will look into the possible solution you propose anyway. You never know.
Cheers!
-Willem
PS; This is the EditRow section with its LoadImplementation. So it is in place, but no data is loaded on a constituent lookup.
<EditRow EditLoadField="PRIMARYRECORDID" DataFormInstanceID="480f8309-de26-46c9-96c2-e2c46270a0c6" DataFormTemplateID="717934c2-d509-4668-a98f-ddfa5159e8a1">
<LoadImplementation SPName="USP_SMU_DATAFORMTEMPLATE_COMMITEDITLOAD_CUBEXTENSION">
<c:CreateProcedureSQL>
<![CDATA[
create procedure dbo.USP_SMU_DATAFORMTEMPLATE_COMMITEDITLOAD_CUBEXTENSION(
@ID uniqueidentifier, -- ConstituentID = PRIMARYRECORDID
@TSLONG bigint = 0 output,
@DATALOADED bit = 0 output,
@USR_ETHNICITIES xml = null output,
@USR_EMAILADDRESSES xml = null output,
@USR_RELIGIONCODEID uniqueidentifier = null output
)
as
beginset nocount on;
set @DATALOADED = 0;
set @TSLONG = 0;-- populate the output parameters, which correspond to fields on the form. Note that
-- we set @DATALOADED = 1 to indicate that the load was successful. Otherwise, the system
-- will display a "no data loaded" message. Also note that we fetch the TSLONG so that concurrency
-- can be considered.
select
@DATALOADED = 1,
@USR_ETHNICITIES = dbo.UFN_SMU_CONSTITUENTUPDATEBATCH_GETETHNICITIES_TOITEMLISTXML(@ID),
@USR_EMAILADDRESSES = dbo.UFN_SMU_CONSTITUENTUPDATEBATCH_GETEMAILADDRESSES_TOITEMLISTXML(@ID);select
@USR_RELIGIONCODEID = RELIGIONCODEID
from dbo.USR_SMU_BATCHCONSTITUENTUPDATERELIGION
where ID = @ID;
return 0;end
]]>
</c:CreateProcedureSQL>
</LoadImplementation>0 -
Ha! I did notice, as I pasted the code, that I am trying to pull from the batch table, instead of pulling from the database record… If the constituent lookup indeed switches to the edit load from the commit section, that may indeed solve the issue. I'll get back to this.
Thanks.
-Willem
0 -
Yeah, that's a no-go.
Also, the Upsert docs make it clear that the PRIMARYRECORDID is used to load the data that is applied to updating an existing record. Comparing new data with existing data is actually done in the save implementation of the EditRow. So it does need to pull from the staging table.
0
Categories
- All Categories
- 6 Blackbaud Community Help
- 213 bbcon®
- 1.4K Blackbaud Altru®
- 402 Blackbaud Award Management™ and Blackbaud Stewardship Management™
- 1.1K Blackbaud CRM™ and Blackbaud Internet Solutions™
- 15 donorCentrics®
- 360 Blackbaud eTapestry®
- 2.6K Blackbaud Financial Edge NXT®
- 655 Blackbaud Grantmaking™
- 576 Blackbaud Education Management Solutions for Higher Education
- 3.2K Blackbaud Education Management Solutions for K-12 Schools
- 939 Blackbaud Luminate Online® and Blackbaud TeamRaiser®
- 84 JustGiving® from Blackbaud®
- 6.6K Blackbaud Raiser's Edge NXT®
- 3.7K SKY Developer
- 248 ResearchPoint™
- 119 Blackbaud Tuition Management™
- 165 Organizational Best Practices
- 241 Member Lounge (Just for Fun)
- 34 Blackbaud Community Challenges
- 34 PowerUp Challenges
- 3 (Open) PowerUp Challenge: Chat for Blackbaud AI
- 3 (Closed) PowerUp Challenge: Data Health
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Product Update Briefing
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Standard Reports+
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Email Marketing
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Gift Management
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Event Management
- 3 (Closed) Raiser's Edge NXT PowerUp Challenge: Home Page
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Standard Reports
- 4 (Closed) Raiser's Edge NXT PowerUp Challenge: Query
- 792 Community News
- 2.9K Jobs Board
- 54 Blackbaud SKY® Reporting Announcements
- 47 Blackbaud CRM Higher Ed Product Advisory Group (HE PAG)
- 19 Blackbaud CRM Product Advisory Group (BBCRM PAG)

