Currently, we are in the process of migrating a ColdFusion 2021 server environment. The old environment was built on CF2016 and MySQL 5.7. The new environment is CF2021 and MySQL 8.0.27. Also, we have split the CF server and the MySQL server, so they are 2 different servers at this point.
We have a function in the CF code which creates csv files (locally) and inserts into a table of the MySQL server.
The query is written like this:
LOAD DATA LOCAL infile 'local-path-to-file' into table op_customer_call_records_work
fields terminated by '|'
lines terminated by '\n'
(master_id,map_id,host_id,,..etc..,cdr_source)
When this attempts to insert, I get this error:
Executing Database Query. (Loading local data is disabled; this must be enabled on both the client and server sides)
I have already set this in the my.cnf:
[client]
loose-local-infile=1
[mysql]
local-infile=1
[mysqld]
local-infile=1
secure-file-priv = ""
and restarted the MySQL server.
My assumption is the [client] tag in the my.cnf file is either incorrect or being ignored. Also, the CF datasource connector uses a java file called: 'mysql-connector-java-8.0.22.jar' if that helps.
Any help would be much appreciated! thanks