delimiter issue during migration

Rakesh Kumar 20 Reputation points
2023-12-22T05:29:09.0533333+00:00

Data is transferred to another column due to our selection of a comma "," as the delimiter when migrating data from the database to the data lake. For instance, in the SQL database, "Da-PJ 'Relax' 19,99" is present in one column.

Consequently, in the CSV file, "Da-PJ 'Relax 19'" occupies one column, and "99" occupies a separate column, leading to this problem.

How do we address this, considering that similar occurrences may happen with other delimiters present in the columns?

Azure Data Lake Storage
Azure Data Lake Storage
An Azure service that provides an enterprise-wide hyper-scale repository for big data analytic workloads and is integrated with Azure Blob Storage.
1,547 questions
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,345 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Subashri Vasudevan 11,221 Reputation points
    2023-12-22T05:40:44.68+00:00

    Hi Rakesh Kumar

    Thanks for your query and using MS Q&A Portal.

    Regarding your query, if your source file is delimited by comma, and you have value like "Da-PJ 'Relax' 19,99", if the string is enclosed in double quotes, you can make use of quote character. This will be fixing the issue. (check the screenshot below) But if your text is not enclosed within double quotes or escaped by any escape character, then we cannot fix it with the copy activity setting. We will have to use our own logic using c#\Python to process the file.

    Screenshot 2023-12-22 at 11.05.21 AM


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.