DVL Software Limited
[ About | Services | Products | Search | Feedback | Support ]

PowerBuilder Tips

Dot notation, memory leaks, and faster data manipulation methods

Back to the Tips

After a quick search on Deja News, I found only one other reference to this type of memory leak.  We were using a dw with about 17,000 rows.  About 18 times per cycle.  So we were getting HUGE leaks.  About 500k per session.

We were doing something like this:

any    la_Price[]
la_Price = ads_365.Object.Data.Primary[1, 4, ll_RowCount, 51]

We changed it to this:

for li_Col = 1 to 48
  ld_Price[li_Col] = ads_365.GetItemNumber(ll_Row, 2 + li_Col)
end for

No more memory leaks.  It takes more time, but so what.  In the long term, we will be using Delphi to accomplish the same task.  We have repeatedly found it quicker to retrieve the data, save it to a text file, pass the file to a Delphi DLL, and get it to produce the answer. B ut in this case, we have 365 rows of 48 columns transposed to 17520 rows, added to another 17520 rows, averages taken, etc.

Similarly for data imports.  We find it faster to use a Delphi DLL to manipulate the data into the correct format, then import it into a DW, then save.  And we're talking 5 - 10 times faster, at least.

Back to the Tips

[ About | Services | Products | Search | Feedback | Support ]

This page last updated: Wednesday, 23 February 2000
Copyright 1997, 1998, 1999, 2000 DVL Software Limited.  All rights reserved.