Nah, I was hoping for a check at the insert stage.
I guess something like:
<cfif SizeOfData(PdfData) GT CFAdmin.Datasources['PdfStorage'].MaxBlobSize>
[throw error]
<cfelse>
[insert data]
</cfif>
A long-winded alternative would be, after the insert, to do a select, write
file, then IsPDF on that, but that seems a bit of an ugly way of doing it.
But that's a fair bit more effort compared to checking numbers.
Maybe a better solution would be a check onApplicationStart that looked at all
the datasources and made sure they had suitable settings - again, that would
need to use cfadmin api stuff - can't remember if that is in CF8 or only CF9?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Want to reach the ColdFusion community with something they want? Let them know
on the House of Fusion mailing lists
Archive:
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:329957
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4