Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I have an app where I already loaded the data of period 2017-2019, but it turns out that part of these data has been changed and I need load the new data but only the fields that have a new value.
Is this possible to do? how can I do that?
Thank you
Regards,
Hi,
you can use an insert update strategy :
DataBase:
SQL SELECT PrimaryKey, X, Y FROM [YOUR_DB_TABLE]
WHERE ModificationTime >= #$(LastExecTime)#;
Concatenate LOAD PrimaryKey, X, Y FROM [YOUR_ACTUAL_DATA]
WHERE NOT Exists(PrimaryKey);
STORE QV_Table INTO File.QVD;
ModificationTime is a field that indicates which fields have been modified.
As long as you have mechanism to capture the change of data you should be able to do that. So question here is , What kind of modification are done in your data (Insert,update)? How you are capturing modification? Using modification Date? If you can provide the change capture mechanism then it will be easy for us to provide accurate solution
Thanks for your time.
Im capturing the modification with the change of the value of the cell. So there is an example:
This is the first load of the data, the column C is the value who may change.
A | B | C |
1 | A | 500 |
1 | A | 1223 |
1 | A | 1245 |
1 | A | 12142 |
1 | A | 7482 |
After some weeks, the value of the first table in column C has change:
A | B | C |
1 | A | 500 |
1 | A | 2000 |
1 | A | 1245 |
1 | A | 13000 |
1 | A | 7482 |
I just need to replace for the new value.
Regards
did you tried what @Taoufiq_Zarra suggested?
Yes but didnt work, im thinking there will be a way to make an IF?? o where exist?
You still have not clarified that how you capture the change. I mean when value gets changed, you are updating any date with change?
at the moment I dont. I will work with source to bring that field.