Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Concatenate tow fields or more..

hello,
I would create a field from other fields. I tried to surround the fields with (*), puisavec "but it does not work !!!

here is my script:
ICP_DATA:
Laod *;
SQL select ....

[...]

STORE ICP_DATA Into $ (vSaveQVD) BILLING.QVD (qvd);

NoConcatenate

load NumSum(Frais1, Frais2) as 'Total Frais Prod',

     "Code Tiers"&"Code Article" as 'Compte Clef',

     Concat(';',Code Sous-Fam. Article,';',C2 Tiers,';') as 'Clef STARR',

     left("Code Tiers",3) as 'Filtre Compte Client',

     Concat(';',Filtre Compte Client,Clef STARR)  as  'Clef STARR ICP'    

Resident ICP_DATA;


The fields ( Frais1, Frais2, Code Sous-Fam. Article,C2 Tiers) are created in the SQL SELECT query.

How to solve this problem?


Regards

4 Replies
CELAMBARASAN
Partner - Champion
Partner - Champion

In Qlikview Concatenation operator is  '&', try like this

';'&[Code Sous-Fam. Article] & ';' & [C2 Tiers] & ';' AS [Clef STARR]

tresesco
MVP
MVP

If you have field names with space in between, you have to enclose them within [] or "". Try like:

  Concat(';',[Filtre Compte Client],[Clef STARR])  as  'Clef STARR ICP'  

Not applicable
Author

Hi,

I would thank you for you help,

I changed ('') by [], but I still have the problem.
but I have the same problem
Found field -
<Filtre Compte Client>

NoConcatenate

Load NumSum(Frais1, Frais2) as 'Total Frais Prod',

     "Code Tiers" & "Code Article" as 'Compte Clef',

     ';' & "Code Sous-Fam. Article" & ';' & "C2 Tiers" & ';' as 'Clef STARR',

     left("Code Tiers",3) as [Filtre Compte Client],

     ';' & "Filtre Compte Client" & "Clef STARR"  as  'Clef STARR ICP'   

Resident ICP_DATA;

is that I should not create a second load just to create 'Clef STARR ICP ??

because [Filtre Compte Client] does not exist in ICP_DATA


Regards

PradeepReddy
Specialist II
Specialist II

You can read only the existing fields from the resident table...

If u want to use the filed [Filtre Compte Client] in your load statement, create the filed [Filtre Compte Client] while loading the data from Database itself.