Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
ashok1203
Creator II
Creator II

How can we show the modified and new records in a chart

Hi Guys,

I have a small requirement like,

I have consists of 100 no.of rows in an Excel. In that, I have updated 5 rows in the Excel and added 10 other rows. How can we display in fronted these 15 records only by dynamically.

Thanks in Advance....!

AAK
19 Replies
ashok1203
Creator II
Creator II
Author

I have attached the sample Excel file to the post. Please find it.

AAK
ashok1203
Creator II
Creator II
Author

Guys, Can any one help me on this issue.

incr.PNG    New to QlikViewQlikView Forums & Resources

AAK
beck_bakytbek
Master
Master

hi Ashok,

i have one Suggestion. why you dont create one column in your table and save new records (changes) in this column, and you can compare you values, example : value = 10, value_new= 12

this is only my Suggestion.

i think that helps you

beck

Anonymous
Not applicable

Hi

Please try this ...

But My suggestion is always go with incremental loading ...

FYI : I have modified your excel data a little ..bit..

INTIALDATA:

LOAD ID,

    Name,

    Location,

    [Posting Date],

    Sales

 

FROM

(ooxml, embedded labels, table is Sheet1);

RIGHT JOIN

//criteria for new data....

NEWDATA1:

LOAD ID,

    Name,

    Location,

    [Posting Date],

    Sales

FROM

(ooxml, embedded labels, table is Sheet2)

WHERE NOT Exists ( Sales);

//criteria for new data....

NEWDATA2:

Concatenate(INTIALDATA)

NEWDATA:

LOAD ID,

    Name,

    Location,

    [Posting Date],

    Sales

FROM

(ooxml, embedded labels, table is Sheet2)

WHERE NOT Exists (ID)

tyagishaila
Specialist
Specialist

By which method you are finding new/updated records in back end.

settu_periasamy
Master III
Master III

Check the attachment

ashok1203
Creator II
Creator II
Author

Hi Settu, I want dynamically i.e we are getting the updated data in the same sheet. Not separately. The Users are Updated  and inserts the new data in the same sheet everyday. So, we need to show only updated  and information infront like your sample application.

AAK
ashok1203
Creator II
Creator II
Author

No, My data should consists all in the single sheet only. No need to change the new data to another sheet. For better understanding i given information like Table1 and Table2 . 

AAK
settu_periasamy
Master III
Master III

Yes, we can store the Initial data as a qvd. then we can compare with updated or new records based on the excel files.

qliksus
Specialist II
Specialist II

Maybe something like this

Consider  that  QVD is having the below data  so in the same excel the new values  are appended which is in the newdata table  . So every time the QVD is loaded make the Flag to empty and whatever the newdata comes in create a Flag for that and also give a unique number to each table

QVDData:
LOAD A, B, RecNo() as QVID1, if(Flag='New','') as Flag INLINE [  
    A, B,Flag
    1, aa
    2, cc
    3, ee
    5, xx
    4, yy
    6, zz
];

newdata:
LOAD * , RecNo() as QVID1, if( not Exists(A,A),'New') as Flag   INLINE [  
    A, B
    1, aa
    2, cc
    3, ee
    5, xx
    4, yy
    6, zz
    5,xx1
    7,vv
   
] ;

Store QVDData into QVDData.qvd;

;In the above scenario  5 and 7 is the update and new record  . To get this in the front end use the below expression

count({<Flag={'New'}>} DISTINCT   A) +count({<A={"=count(distinct B)>1"}>} DISTINCT   A)