I'm trying to set some fields and save them to a database using this code on the add page Javascript onload event:
var ctrl = Runner.getControl(pageid, 'ETL_NaturalKeyText');
ctrl.setValue("5493001WHVQBGRSWEU75NE022589364");
pageObj.hideField('ETL_NaturalKeyText');
when I remove the hidefield line it will save the record just fine. But when I have that line in it results in this error:
Source: Microsoft SQL Server Native Client 11.0 Description: Cannot insert the value NULL into column 'ETL_NaturalKeyText', table 'HMDA_DW_Staging.dbo.HMDA_Reporting_staging'; column does not allow nulls. INSERT fails. The statement has been terminated.
Any idea's why?
var ctrl = Runner.getControl(pageid, 'ETL_NaturalKeyText');
ctrl.setValue("5493001WHVQBGRSWEU75NE022589364");
pageObj.hideField('ETL_NaturalKeyText');
when I remove the hidefield line it will save the record just fine. But when I have that line in it results in this error:
Source: Microsoft SQL Server Native Client 11.0 Description: Cannot insert the value NULL into column 'ETL_NaturalKeyText', table 'HMDA_DW_Staging.dbo.HMDA_Reporting_staging'; column does not allow nulls. INSERT fails. The statement has been terminated.
Any idea's why?