I created a batch file:
c:
cd '\export data'
set cmd="C:\Program Files\MySQL\MySQL Server 5.7\bin\mysql"
%cmd% --login-path=import dbexport -v -v <importalltables.sql >import_results.log 2>import_err.log
----------
The login-path is set up correctly. This batch file works when I am logged into the server. When I schedule a Windows task to execute it and give it my userid and password in the task, it issues the error message 'ERROR 1045 (28000): Access denied for user 'ODBC'@'localhost' (using password: NO)' and dies.
c:
cd '\export data'
set cmd="C:\Program Files\MySQL\MySQL Server 5.7\bin\mysql"
%cmd% --login-path=import dbexport -v -v <importalltables.sql >import_results.log 2>import_err.log
----------
The login-path is set up correctly. This batch file works when I am logged into the server. When I schedule a Windows task to execute it and give it my userid and password in the task, it issues the error message 'ERROR 1045 (28000): Access denied for user 'ODBC'@'localhost' (using password: NO)' and dies.