11,677
edits
Changes
Updating to match new version of source page
With TaticView, you can automate the update of your [[Data_Sources|Data Files]].
<span style="color: red;">'''Important:'''</span> * To use TVCli works with , the computer where it will be configured must have java from version <i>7.0_808</i>installed. If you use a Java minor version the message "Unsupported major. Howeverminor version 52.0" will be showed, we recommend using <em>see [[Java 8JRE install and troubleshooting]] for help.* A notification will be displayed to the user if an error occurred during the data update.* A log with the execution details will be generated in the user's settings folder (Example: </emi> because C:\Users\<iuser>Java 7\AppData\Local\TVCli\Logs</i> is discontinued by Oracle).
=== Installing TVCli ===
For now, we have only a user friendly installer for Windows. If you need install TVCli in other platforms, please contact us at <u>[https://support.taticview.com Support]</u>. We are glad to to help you to install it in you environment.
The browser can try to block the installer download. If you can't download please enter in contact with our support.
Windows can too block the installer execution to protect the computer. In this case continue the installation choosing the advanced options.
In both situations if you need contact us to help you.
* '''Run the installation''' on the computer where the schedules will be created to run the TVCli.
To automate the data updates through TCVli, it is necessary to own an '''[[Manage_Access#Tokens|Access TOKEN]]''' created on TaticView and then register it on TVCli.
There are two ways to generate an Access TOKEN:
====Using TVCli command line====Run the command through a command line requesting the generation of an [[Manage_Access#Tokens|Access TOKEN]]. To help you on this, we wave a [[TVCli Commands|Wizard]] Command Syntax: '''tvcli -cmd get_token_by_password -user <your TaticView user> -password <your TaticView password> [-token_name "<token name>"]''' -cmd - get_token_by_password - Requests The command responsible for requesting and stores storing the ACCESS Access TOKEN through command lineon the TVCli settings. (TVCli) -user - Your TaticView user(access email). -password - Your TaticView access password. -token_name (optional) - The name that you want to give set to the access tokenyour Access TOKEN. Default The default name "'''TaticView CLI" ''' will be set if you do not specify a name.
Example:
'''tvcli -cmd get_token_by_password -user myemail@email.com -password 123466 -token_name "TVCli Server 1" '''
Command Syntax: '''Syntax: tvcli -cmd store_token -user <your TaticView user name> -token <the token generated tokenon TaticView>'''
-cmd - store_token - stores token The command responsible for storing the TOKENS generated through the interfaceon TaticView. -user - Your TaticView user (access email). -token - The token generated through the interfaceon TaticView.
Example:
'''tvcli -cmd store_token -user meuemail@email.com -token 9bdr845gh5r4r1vd5d5'''
=== Updating your data automatically ===
Then, the ''Automatic importation'' option should be enabled. When you do this, you will see the data file code, as in the example below:
[[File:automatic-importation+en-US.pngPNG]]
Command Syntax: '''Command Syntax: tvcli -cmd import_file -user <your TaticView user> -datamart <data file identification code> -file "<file/spreadsheet address>" [-type "<type>"] [-wait [-notifyshare]] [-nonotifyerror]
'''
-cmd - import_file - Command that uploads the data file your files and places it in add them to the import update queue. -user - Your TaticView user (access email). -datamart - identifier The identification code of the data file obtained in through the Data file properties at option on the interfaceTaticView main page. -file - Text data file The address of the text (CSV) or spreadsheet (XLSX,XLS, XLSM) to data file that will be importedupdated. You can use mapped drives (Ex.: C:\, D:\) or UNC address (Ex.: \\server\folder\file). -type (opcional) - clear_and_add - Deletes all every data from the TaticView 's Data File and imports the new data. (This is TVCli's default)behavior. append - Adds the It adds new data at to your TaticView's data files file/spreadsheet while still keeping the end of the TaticView Data Filepreviously imported data. It is necessary 's important to make sure to be careful not to duplicate any data. -wait (opcional) - waits for Command that makes TVCli wait the end of the importyour data updates along with TaticView. It is needed 's necessary in case you want to test '''Output Status'''commands responses (ERROR_LEVEL). -nonotifyerror (opcional) - does Command used to not notify the user if in case of an error occurs occurring during the update process. -notifyshare (opcional) - sends data update Command used to send a notification to the users who have these data file own shared dashboards shared when informing that the importing process ends without errorsdata update finished successfully. Only This command only works when used with the <i>-wait. '''Example:''' '''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "c:\taticview\imp\spreadsheet.xlsx"''' '''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "c:\taticview\imp\file.csv" -wait -notifyshare''' '''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "c:\taticview\imp\spreadsheet.xlsx" -wait''' '''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "c:\taticview\imp\spreadsheet.xlsx" -type clear_and_add''' '''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "c:\taticview\imp\spreadsheet.xlsx" -type append''' '''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "c:\taticview\imp\spreadsheet.xlsx" -type append -nonotifyerror''' === TVCli version === Shows TVCli version on console and register into log file</i> command.
Example:
'''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "\\servidor\taticview\imp\myspreadsheet.xls" '''
'''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "C:\taticview\imp\spreadsheet.xlsx"'''
'''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "C:\taticview\imp\file.csv" -wait -notifyshare'''
'''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "C:\taticview\imp\spreadsheet.xlsx" -wait'''
'''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "C:\taticview\imp\spreadsheet.xlsx" -type clear_and_add'''
'''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "C:\taticview\imp\spreadsheet.xlsx" -type append'''
'''tvcli -cmd import_file -user myemail@email.com -datamart 246 -file "C:\taticview\imp\spreadsheet.xlsx" -type append -nonotifyerror'''
'''Call "C:\Program Files\TvCli\tvcli" -cmd import_file -user myemail@email.com -datamart 246 -file "D:\taticview\imp\spreadsheet.xlsx" -wait'''
You can create BAT files to schedule a bunch of TVCli commands. Doing so the entire process can be automated. As you can schedule using Windows scheduler or other similar tool.
At end of a command execution, TVCli returns specific codes to inform the success or failure of the command. This allows the BAT file to verify if the previous TVCli command was completed successfully.
if %errorlevel% == 0 (
echo SALES updated successfully!
) else (
echo Problems updating SALES!
)
=== = BAT (Script ) example ====Bellow we show you a script sample that imports two files to different DataMarts (ids 674 and 673) and test the ERRORLEVEL environment variable to evaluate if the data update was done successfully.
'''if %errorlevel% == 0 (
'''echo "SALES updated successfully!"
''') else (
'''echo "Problems updating SALES!"
''')
'''call C:\TaticView\tvcli -cmd import_file -user jonathanmy@sadigemail.com -file "C:\Users\jonathan.Sadig\Documents\TaticView\Import Files\hr.xlsx" -datamart 673 -wait
'''if %errorlevel% == 0 (
'''echo "HR updated successfully!"
''') else (
'''echo "Problems updating HR!"
''')'''
=== More questions on how generate the automation commands? ===
TaticView has a wizard the help you on this, on the Data Files properties screen, when clicking the link <i>help to generate automation commands?</i>, it will display the [[TVCli Commands]] screen, where you can obtain preset TVCli commands. All you have to do is inform some required data.
You can also open a [https://support.taticview.com/open.php/?&lang=en_US support ticket]. In case you are having problems during the TVCli configuration process. It will be a pleasure to help you.