This post might help you.
@cookie clicker: Set input file path and filename InputFile = "C:\data\timestamp_import.csv"
Set Anaplan model and module information ModelName = "My Model" ModuleName = "My Module" ListName = "My List"
Set date/time format for timestamp column DateTimeFormat = "yyyy-MM-dd HH:mm:ss"
Import timestamp values from CSV file ImportData { File = InputFile Delimiter = "," SkipHeader = true
ini Copy Column "Timestamp" { Type = DateTime Format = DateTimeFormatMap = ListName } }
Validate and commit the import ValidateImport CommitImport [/Anaplan Batch Script]
This script assumes you have a CSV file named "timestamp_import.csv" with a column containing timestamp values. It sets the date/time format for the timestamp column, imports the data into the specified Anaplan model and module, and then validates and commits the import.
@Sarthak18
This will work too. A lot will depend on the command prompt you use in terms of formatting the date. This method uses the command line using windows. Also shows how to do in Python.
@snow rider 3d
:: Set Anaplan Connect directory set ANAPLAN_CONNECT_DIR=C:\path\to\anaplan-connect
:: Set Anaplan credentials set ANAPLAN_USER=your-email@example.com set ANAPLAN_PASS=your-password
:: Set Anaplan workspace and model information set WORKSPACE_ID=your_workspace_id set MODEL_ID=your_model_id
:: Set the import action and the file to be uploaded set IMPORT_ACTION=Import_Timestamp_Action set FILE_TO_IMPORT=timestamp.csv
:: Generate the timestamp for /f "tokens=1-4 delims=/: " %%d in ("%date% %time%") do ( set timestamp=%%d-%%e-%%f %%g:%%h:%%i )
:: Create the CSV file with the timestamp value echo "Timestamp" > %FILE_TO_IMPORT% echo "%timestamp%" >> %FILE_TO_IMPORT%
:: Run the Anaplan Connect script to import the CSV file cd %ANAPLAN_CONNECT_DIR% call anaplan.bat -u %ANAPLAN_USER% -p %ANAPLAN_PASS% -workspace %WORKSPACE_ID% -model %MODEL_ID% -file %FILE_TO_IMPORT% -put %FILE_TO_IMPORT% -import %IMPORT_ACTION% -execute -output log.txt
:: Clean up del %FILE_TO_IMPORT%
@echo on
There was an error rendering this rich post.
Hi all, The Client ID and Client Secret are available, intended for uploading and downloading files. Could anyone advise how to use these credentials DIRECTLY to make API requests? Thank you!
I have A6 as the parent list and two sibling lists: A6.5 and A7. The A7 list includes an attribute that maps to A6.5. In the UX, the user will select A6.5 using a content selector, and the grid (dimensioned by A7) should display only the A7 items associated with that selected A6.5. Since the selector is a page context and…