Azure Data Factory "Name File as column data" option in Sink transformation of data flow is creating blobs name for virtual folder - azure-data-factory-2

I have create and ADF pipeline. Source and sink, both are storage account.
I want to create file based on date in column data, so I selected the option "File Name as Column Data".
In this option, we are giving filename, with virtual folder path.
But when process is completed, blob(hot inferred) also created for virtual folder, which I don't need. I just need blob for files(which is also present). If I delete those virtual folder blobs, I cant put the file in incremental way in those folder.
What should I do?

You should set the column format first in source projection before set "File Name as Column Data".
Here's my source file:
Source projection settings: specify the column date type and format.
Sink settings:
Output:
Then we can get the output files without the virtual folder.
HTH.

Related

Create a ADF Dataset to load multiple csv files (same format) from the Blob

I try to create a dataset containing multiple csv files from the Blob. In the file path of dataset setting: I create a parameter - #dataset().FolderName and add FolderName in the Parameters.
I leave file (from File Path) empty as I want to grab all files in the folder. However, there is no data when I preview data. Is there anything missing? Thank you
I have tested it on my side and it can work fine.
add FolderName parameter
preview data
If you want to merge all csv files in Data Flow, you can do this:
1.output to single file
2.set Single partition

load file with csv extension in ssis

I have to load file with csv extension from one particular folder to data base in ssis. file name is not known but folder and extension is fixed.
To load the content of a file, the file name with folder path is required else the connection manager can not be validated and configured.
The easiest way is to get file name is using a For Each Loop container:
Select the option [Foreach File Enumerator]
Provide the Folder path and extension (like *.csv) you already have.
Get the File Name in a variable and use it within the Source of the data flow task within the For each Loop container.
Refer

pentaho data integration dynamic file name

New to PDI here. Need to output data from a view in a postgresql database to a file daily. The output file will be like xxxx_20160427.txt, so need to append the dynamic date in the file name. How to do it?
EDIT-----------------
I was not clear here by asking how to add dynamic date, I was trying to add not just date but optional other parts to the file name. E.g adding a serial no (01) at the end: xxxx_2016042701.txt etc. So my real question is how to make a dynamic file name? In other ETL tool e.g. SSIS it will be a simple expression. Not sure how it is done in PDI?
In your Text file output step, simply check "Include date in filename?" under the files tab.
You can create a dynamic filename variable with a Modified Java Script value STEP.
and then in the Text File Output STEP click on "Accept file name from field", and select your variable declared from previous step (filename_var on this example).

BIDS Import from changing file name [wildcard?]

I'm attempting to create a process to import data. I created the entire process and it works, but I'm having trouble creating the variable to find the file name of the csv i want to import automatically. Each time a new csv is uploaded to me it has a timestamp on it. I want to be able to grab that file no matter what the name is and do work to it.
So for example this week the file name would be
filename_4-14-2014.csv
And next week
filename_4_21_2014.csv
And so on into eternity. . .
Is there a way to create a variable that picks up the full file name even though its changing?
After doing some poking around, I've discovered the following...
You can use a file system task to perform the copy operation I was referring to. You can set the input file and the output file as variables. This way you can always know that the file you use for import is always named the same, and has the right data.
You just need to add the variables and a File System Task to your package.
Ok so to accomplish what I wanted I created a Foreach Loop Container. Using the foreach loop container I had it look for any files ending with .csv in my specified folder by using a wildcard [denoted by asterisk: *.csv] .
Within the Foreach Loop container is as follows.
Step 1: File System Task - rename file.
Step 2: Data Flow Task - Import data to sql
Step 3: File System Task - Copy the file to another folder, append datetime to filename
Step 4: File System Task - Delete source file.
I used variables to get all the file and folder names plus datetimes.

Edit the control file in Oracle 10g Release 2

I tried to clone an oracle database server to another oracle database server.
After I completed the cloning, when I tried connecting to the database by starting SQL Plus
I got the following errors:
ORA-01157: cannot identify/lock data file 1 - see DBWR trace file
ORA-01110: data file 1: '/home/oracle/oradata/ccisv2/system01.dbf'
I found that while cloning the control file of the original database location also got cloned.
Now in the new server I have the data files located at a different location. and that is not affected in the control file, which is the reason for the error.
In short I need to change the above path
/home/oracle/oradata/ccisv2/
to a new path
/home2/oracle/oradata/ccisv2/
I am not sure how can I change the control file and edit the path of the data file location.
Changing of the location of datafiles is not possible as I have less space in
/home/oracle/oradata/..
Can some one help me with this one...
You'll need to mount the database (not open it) and re-create the controlfile, renaming the data files in the process (see the CREATE CONTROLFILE command):
STARTUP MOUNT;
CREATE CONTROLFILE REUSE SET DATABASE "ORCL" RESETLOGS
MAXLOGFILES NN
MAXLOGMEMBERS N
MAXDATAFILES 254
MAXINSTANCES 1
MAXLOGHISTORY 1815
LOGFILE
GROUP 1 '/home2/oracle/oradata/ccisv2/REDO01.LOG' SIZE 56M,
GROUP 2 '/home2/oracle/oradata/ccisv2/REDO02.LOG' SIZE 56M,
GROUP 3 '/home2/oracle/oradata/ccisv2/REDO03.LOG' SIZE 56M
DATAFILE
'/home2/oracle/oradata/ccisv2/SYSTEM.DBF',
'/home2/oracle/oradata/ccisv2/USERS.DBF',
'/home2/oracle/oradata/ccisv2/sysaux.DBF',
'/home2/oracle/oradata/ccisv2/TOOLS.DBF',
etc...
CHARACTER SET WE8ISO8859P1;
ALTER DATABASE OPEN RESETLOGS;
QUIT;
All of your database files need to be re-identified in the controlfile with their new location.
Easiest is to just rename the datafiles to the new locations:
startup mount;
alter database rename file '/home/oracle/oradata/ccisv2/system01.dbf' to '/home2/oracle/oradata/ccisv2/system01.dbf';
and do this for all your files.
Normally we would use rman duplicate and use the file_name convert to do this for us.
re-creating the controlfile is also an option, renaming the files is easier.