Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How to add a column and store it

Hello qlikers 🙂 ,

I am loading a qvd file. After this qvd file I want to write a new column to it and store it.

User:
LOAD
    "ID",
    User,
    "Time",
    "End Time",
FROM [lib://User.qvd];

// Add new column
// for example
// ID = $(vIDNew)
//...
Store IT User into UserNew.qvd (qvd);

How could I add a new  column  with values and add it to the table user and store it finally?

Thank you in advance! Looking forward to reading some answers. 🙂

Labels (2)
1 Solution

Accepted Solutions
Kashyap_R
Partner - Specialist
Partner - Specialist

Hi

 you can use inline load instead of creating  variables for the user, id 

create variables only for the time and end time

if you want constant use set else to use let to update new every time you load the data

Let / Set  Time = Now()
Let / Set  EndTime = Now()

Concatenate(User)

Load * Inline [

ID, User, Time, EndTime

5, 'Testname',$(Time ),$(EndTime )];

Hope this helps

Thanks

Thanks and Regards
Kashyap.R

View solution in original post

3 Replies
Kashyap_R
Partner - Specialist
Partner - Specialist

Hi

Can u please elaborate what value do u want to insert into new column and data is coming from excel or which source?

Thanks

Thanks and Regards
Kashyap.R
Anonymous
Not applicable
Author

Thank you for your answer!

Dats is coming from a qvd, it was excel but I store it as a qvd. A csv file would match also. 

This would be data: 

ID = '5'
SET vUsername = 'Testname'
User = $(vUsername)
Time = Now()
End Time = Now()

Is the information enough for you ? Please let me know! Thank you in advance! 🙂

Kashyap_R
Partner - Specialist
Partner - Specialist

Hi

 you can use inline load instead of creating  variables for the user, id 

create variables only for the time and end time

if you want constant use set else to use let to update new every time you load the data

Let / Set  Time = Now()
Let / Set  EndTime = Now()

Concatenate(User)

Load * Inline [

ID, User, Time, EndTime

5, 'Testname',$(Time ),$(EndTime )];

Hope this helps

Thanks

Thanks and Regards
Kashyap.R