I'm trying to remove a Date To date from a constituency code through API. Is there a way to do this? I'm getting the error RE7.dbo.CONSTITUENT_CODES'; column does not allow nulls. INSERT fails when I try to add a blank to the field.
I tried making it equal to Null but that doesn't work either. Is there an easy way to remove this date?
Thanks.
Lisa
1 Comment
T
Travis Mayne
said
over 5 years ago
Set the "Date To" field to an empty string. Obviously, you would have to loop through and target the constituent code in question
PSUEDO-CODE below:
Dim oCode As Blackbaud.PIA.RE7.BBREAPI.CConstituentCode
For Each oCode In oRec.ConstituentCodes
If oCode.Fields(Blackbaud.PIA.RE7.BBREAPI.ECONSTITUENT_CODEFields.CONSTITUENT_CODE_fld_CODE) = "Staff" And oCode.Fields(Blackbaud.PIA.RE7.BBREAPI.ECONSTITUENT_CODEFields.CONSTITUENT_CODE_fld_DATE_TO) "" Then
Lisa Folger
Hi,
I'm trying to remove a Date To date from a constituency code through API. Is there a way to do this? I'm getting the error RE7.dbo.CONSTITUENT_CODES'; column does not allow nulls. INSERT fails when I try to add a blank to the field.
I tried making it equal to Null but that doesn't work either. Is there an easy way to remove this date?
Thanks.
Lisa