Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
RA6
Creator
Creator

Defining specific characters limit of columns

Hello,

 

I have a csv file and for each column i want to define a specific limit of characters for each of them.

 

0683p000009LrB9.png

 

Example:

0683p000009LqzR.png

 

In my expected output :

Adresse : Limit characters to 10 only

Telephone : Limit characters to 7 only

Ville : Limit characters to 15 only

 

0683p000009LrDm.png

 

Apart making use of SubString expression, can the above result be achieved?

 

Is there a way to define my characters limit?

 

I have also tried to define them in the schema length but in vain?

 

0683p000009LrDr.png

 

 

Best regards,

asadasing

Labels (3)
1 Solution

Accepted Solutions
SachinD
Creator
Creator

Hi,

 

You can use tSchemaComplianceCheck, as done below

 

0683p000009LrDs.jpg0683p000009Lr26.jpg0683p000009LrEB.jpg

View solution in original post

6 Replies
SachinD
Creator
Creator

Hi,

 

You can use tSchemaComplianceCheck, as done below

 

0683p000009LrDs.jpg0683p000009Lr26.jpg0683p000009LrEB.jpg

Vinlogs
Creator
Creator

Hi Asadasing,
Sachinddhake's response is perfect! I have already implemented such logic to achieve what you were looking for! So you can adopt that solution with no doubt, accept his answer and let the Talend community make use of this amazing idea! Thanks Sachin. You rock!!
RA6
Creator
Creator
Author

Hello Sachin and Vineet,

Thank you for your response.

My problem is that i don't want to rejet the data that exceed the max length but i want to process the data with the specific max length i have define.

Example:
Telephone length in input file = 10 or greater
Max Length defined : 7

In the output, it has to process the telephone qith only 7 characters.

Is this possible with tSchemaComplianceCheck?

Best regards,
asadasing
RA6
Creator
Creator
Author

Solution found.

In tSchemaComplianceCheck, i can trim the excess content of column according to the length defined.

SachinD
Creator
Creator

Thanks @asadasing, for accepting the solution and sharing tSchemaComplianceCheck Trim configuration.

Also Thanks to @Vineet for Kind words..

 

Lets share and Learn new things !!

 

Thanks,

Sachin

 

 

 

Vinlogs
Creator
Creator

Well said @Sachin, Sharing helps learning faster 0683p000009MACn.png thanks