(( See Also: Qlik Replicate - S3 Endpoint - Dynamic Folder Name - Qlik Community - 2019934 ))
Create an S3 Replication Profile option during New Task creation, where the Target Endpoint data would be treated more like files instead of Database Schema/Table/Column/etc... fields, and the Target Endpoint itself would simply be a pointer to a top level directory.
For example, in an S3-Replication-Profile task, I would select the Source Schema/Tables/Columns - but in the S3 Task type, instead of "Map to target table" it would have "Map to Folder" options (that would include the capability to add a dynamic formula field- ie: DATE).
IE:
- Target Endpoint S3 Bucket Name = my-s3-bucket-name
- Target Endpoint S3 Target Folder = dir1/dir2/dir3/subfolder
- S3 Replication Task Settings Option: Target Folder = {DATE_VAR}
- -or, less desirable, a setting within each Table Mapping of each Replication Task-
- Target Subfolder Name (instead of Table Schema/Table Name fields) = {DATE_VAR}
-
Would result in:
- Full Path (from 12/25/2022) = my-s3-bucket-name/dir1/dir2/dir3/subfolder/12-25-2022/table_name/fileload00001.parquet
- Full Path (from 12/26/2022) = my-s3-bucket-name/dir1/dir2/dir3/subfolder/12-26-2022/table_name/fileload00001.parquet
Thanks for your time!
-mp