Anaplan Connect 1.4.4 Upload Error

Highlighted
New Contributor

Anaplan Connect 1.4.4 Upload Error

Hello community

 

I try to run Anaplan connect to import data from my local computer with email and password.

But it doesn't work.

I've already set import file as Admins Only.

 

I don't understand just this error blow what is wrong. 

ERROR [c.a.client.Program :650 ] 9204 |-- Anaplan API:

Could you tell me what is wrong?

 

Anaplan connect error.png

bat script

-------------------------------------------------------------------------------------

@Echooff
rem For Windows OS : This example explains the usage of basic Authentication with Anaplan Connect.
rem It also loads a source text file and runs an Anaplan import into a module.
rem For details of how to configure this script visit https://help.anaplan.com/anapedia/Content/Downloads/DL_Downloads.html

set AnaplanUser="email:password"
set WorkspaceId=""
set ModelId=""
set ServiceUrl="https://api.anaplan.com"
set AuthUrl="https://auth.anaplan.com"
set Chunksize="1"


set Operation=-debug -service %ServiceUrl% -auth %AuthUrl% -workspace %WorkspaceId% -model %ModelId% -chunksize %Chunksize% -file "問題37.csv" -put "C:\anaplan-connect\ANY_files\問題37.csv" -import "問題37_import" -execute -output "問題37.csv_dump"
rem *** End of settings - Do not edit below this line ***

setlocal enableextensions enabledelayedexpansion || exit /b 1
cd %~dp0
if not %AnaplanUser% == "" set Credentials=-user %AnaplanUser%
set Command=.\AnaplanClient.bat %Credentials% %Operation%
@Echo%Command%
cmd /c %Command%
pause

13 REPLIES 13
Highlighted
Certified Master Anaplanner

Re: Anaplan Connect 1.4.4 Upload Error

Hi @yiseki 

 

Just wanted to know is the script in the same folder where you have downloaded the Anaplan API ?

 

Thanks,

Thanks,
Nakul
Highlighted
New Contributor

Re: Anaplan Connect 1.4.4 Upload Error

YES.

I placed folder of Anaplan-connect under the C drive like this below.

And the script is in its folder that is drawn red line . 

Anaplan connect reply1.png

 

Highlighted
Certified Master Anaplanner

Re: Anaplan Connect 1.4.4 Upload Error

Hi @yiseki 

 

Apologies, Are you running the script on Linux , Mac OS or Windows ?

 

Because i see the starting of the script is starting as Windows but in middle is it Mac OS and Linux. 

 

Can you confirm ?

 

Thanks,

Nakul

Thanks,
Nakul
Highlighted
New Contributor

Re: Anaplan Connect 1.4.4 Upload Error

@NakulAggarwal 

 

I am running the script only on Windows.

 

I'm so sorry that I didn't arrange files.

It makes you confuse...

 

thanks,

yiseki

 

Highlighted
Certified Master Anaplanner

Re: Anaplan Connect 1.4.4 Upload Error

Hi @yiseki 

 

please try the below script between the dotted line:- 

 

Please double check the file name and Import name in your local language and update Email/Password/WorkspaceID/ModelID:-

 

-------------------------------------------------------------------------------------

@Echo off
rem This example loads a source text file and runs an Anaplan import into a module.
rem For details of how to configure this script see doc\Anaplan Connect User Guide.doc

set AnaplanUser="email:password"
set WorkspaceId=""
set ModelId=""
set Operation=-service "https://api.anaplan.com" -auth "https://auth.anaplan.com"
-file "問題37.csv" -put "C:\anaplan-connect\ANY_files\問題37.csv" -import "問題37_import" -execute
-output "C:\anaplan-connect\My Errors.txt" 

rem *** End of settings - Do not edit below this line ***
setlocal enableextensions enabledelayedexpansion || exit /b 1
cd %~dp0

if not %AnaplanUser% == "" set Credentials=-user %AnaplanUser%
set Command=.\AnaplanClient.bat %Credentials% -workspace %WorkspaceId% -model %ModelId% %Operation%
@Echo %Command%
cmd /c %Command%
pause

-------------------------------------------------------------------------------------

 

Do let me know if you still face some issue.

 

Thanks,

Nakul

 

Thanks,
Nakul
New Contributor

Re: Anaplan Connect 1.4.4 Upload Error

hello@NakulAggarwal 

 

Thank you for sharing the scripts!

 

I checked email:password and model ID, workspace ID.

THEN I tried to run it.

 

But I faced same error.
Do you have any idea why the error is occurred?

yiseki_0-1592992756476.png

 

Thanks,

yiseki

Highlighted
Frequent Contributor

Re: Anaplan Connect 1.4.4 Upload Error

Hi,

I guess it is an issue with the character encoding, try saving your batch file in UTF-8

Also Run that batch file in code page 65001.

 

Regards

Highlighted
New Contributor

Re: Anaplan Connect 1.4.4 Upload Error

HELLO@ABerenguela 

 

I tried to save batch file in UTF-8.

And changed code page 65001 in console.

Beside,I also tried to save AnaplanClient.bat in UTF-8.

 

 

I faced same issue.

yiseki_0-1593047349902.png

 

 

Regards,

yiseki

Highlighted
Certified Master Anaplanner

Re: Anaplan Connect 1.4.4 Upload Error

Hi @yiseki 

 

My team was trying the same on one of the servers and they faced the same issue, they resolved it by adding the a proxy in the script :-

 

.............................................................

 

@Echo off
rem This example loads a source text file and runs an Anaplan import into a module.
rem For details of how to configure this script see doc\Anaplan Connect User Guide.doc

set AnaplanUser="email:password"
set WorkspaceId=""
set ModelId=""
set Operation=-service "https://api.anaplan.com" -auth "https://auth.anaplan.com"

 

-via "PROXY:PORT" -file "問題37.csv" -put "C:\anaplan-connect\ANY_files\問題37.csv" -import "問題37_import" -execute
-output "C:\anaplan-connect\My Errors.txt" 

 

rem *** End of settings - Do not edit below this line ***
setlocal enableextensions enabledelayedexpansion || exit /b 1
cd %~dp0

if not %AnaplanUser% == "" set Credentials=-user %AnaplanUser%
set Command=.\AnaplanClient.bat %Credentials% -workspace %WorkspaceId% -model %ModelId% %Operation%
@Echo %Command%
cmd /c %Command%
pause

 

.................................

 

If you can try this once by adding a proxy and Port in the script.

 

Thanks,

Nakul

Thanks,
Nakul