In CiviCRM 4.7: fatal constraint violation while enabling the extension
Created by: mlutfy
I feel like the sql/install.sql statement is not necessary?
I had the following error while enabling the extension on CiviCRM 4.7.13:
INSERT INTO civicrm_managed (module, name, entity_type, entity_id)
VALUES ('ca.civicrm.moneris','Moneris','PaymentProcessorType',
(SELECT id FROM civicrm_payment_processor_type where name = 'Moneris'))
[nativecode=1048 ** Column 'entity_id' cannot be null]
After I commented the statement out of the .sql file and re-installed the extension, the civicrm_managed
table seemed OK:
| id | module | name | entity_type | entity_id | cleanup |
[...]
| 32 | ca.civicrm.moneris | Moneris | PaymentProcessorType | 13 | NULL |
| 33 | ca.civicrm.moneris | Cron:Job.Monerisrecurringcontributions | Job | 18 | NULL |