Highlighted

Query Not Working

Explorer ,
Jul 11, 2016

Copy link to clipboard

Copied

The following query keeps aborting in Coldfusion:

SELECT ID, BusinessName, dba, BusinessPhone, FEIN, CSLB, WCRenewalDate, WCCarrier, CACarrier, CANumber, CARenewalDate, GeneralLiabilityCarrier, HealthInsuranceCarrier, HealthInsuranceRenewal, GeneralLiabilityRenewal
FROM PProspect
ORDER BY BusinessName

The query runs just fine if I use it within the phpMyadmin mySQL interface, but when I try to use it within a CFQUERY tag, it fails every time. I tried all of the field names within a CFQUERY individually, and they all work except for the HealthInsuranceRenewal and GeneralLiabilityRenewal fields. The other two date fields (WCRenewalDate and CARenewalDate) work just fine. All of the date fields are configured the same way in mySQL -- type = date and default = NULL.

Any idea why this is happening?

TOPICS
Getting started

Views

292

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Query Not Working

Explorer ,
Jul 11, 2016

Copy link to clipboard

Copied

The following query keeps aborting in Coldfusion:

SELECT ID, BusinessName, dba, BusinessPhone, FEIN, CSLB, WCRenewalDate, WCCarrier, CACarrier, CANumber, CARenewalDate, GeneralLiabilityCarrier, HealthInsuranceCarrier, HealthInsuranceRenewal, GeneralLiabilityRenewal
FROM PProspect
ORDER BY BusinessName

The query runs just fine if I use it within the phpMyadmin mySQL interface, but when I try to use it within a CFQUERY tag, it fails every time. I tried all of the field names within a CFQUERY individually, and they all work except for the HealthInsuranceRenewal and GeneralLiabilityRenewal fields. The other two date fields (WCRenewalDate and CARenewalDate) work just fine. All of the date fields are configured the same way in mySQL -- type = date and default = NULL.

Any idea why this is happening?

TOPICS
Getting started

Views

293

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Jul 11, 2016 0
scotwllm LATEST
Explorer ,
Jul 12, 2016

Copy link to clipboard

Copied

Turns out that I changed the defaults for the HealthInsuranceRenewal and GeneralLiabilityRenewal fields. Some of them had 0000:00:00 in them and some had NULL. I deleted the two columns (luckily I had very little data in them), re-created them, and now it's working fine.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Jul 12, 2016 0