- Sivaprakash BKR
- PowerBuilder
- Tuesday, 10 January 2023 06:14 AM UTC
Hello
PB 2022 build 1892
Need to export data from a datawindow to three different JSON string.
1. All deleted rows
2. All modified rows
3. All inserted rows
For deleted rows: dw_1.ExportJSON(Delete!, 1, 0, 1, 5) Works!
For 2 & 3, there seems to be only one way. To use
string dwcontrol.ExportJson( {DWBuffer dwbuffer,} boolean changedonly, boolean format )
The above command exports all data that have been either modified or newly inserted. But I want these two data in two different JSON string, so that proper DML statements could be generated by the server side scripts.
The other way could be to process every row, check the row status and if that matches generate JSON for that row. But performance wise ExportJSON seems better.
Any solution?
dw_1.ExportJSON(DWBuffer dwbuffer, RowStatus rowstatus, boolean format) might do the work. Is that command or similar one available?
Happiness Always
BKR Sivaprakash
Find Questions by Tag
Helpful?
If a reply or comment is helpful for you, please don’t hesitate to click the Helpful button. This action is further confirmation of their invaluable contribution to the Appeon Community.