Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi guys,
I'm trying to load data from files stored into a server shared directory, whose path is clearly differentent from user to user.
I'm actualy using this:
DIRECTORY
for each File in filelist('*.xlsx')
LOAD *
FROM
[$(File)]
(ooxml, embedded labels, header is 1 lines, table is Contatti);
next File;
it works... ok
The problem is that one of my collegue has to change the directory to it's own path
DIRECTORY
to make it works.
Is there any set of instructions to set the path dinamicaly?
I tried with
load
Getfolderpath('DashBoard') as dropBox
AutoGenerate 1;
DIRECTORY [$(dropBox)\Contatti\Piani];
but doesnt'work...
any suggestion?
thanks to all
then you can directly read from xlsx in the script as follows:
load *
from Piani\name_of_excel_file
you don't need to go to root then access folder; it is already near the qvw file
Hi
I use a variable set up i.e.
Set vUser= 1; // 1 = Bob, 2 = John
if $(vUser) = 1
Let vFolderPath = '\\Bob Server\Bob directory\';
ElseIf $(vUser) = 2
Let vFolderPath = '\\John Server\John directory\';
End If
Then I make sure that everywhere that uses a file path uses $(vFolderPath) instead.
All the user has to do is make sure that the vUser value is changed prior to reloading.