Forum > Databases
IBX - Buffer Chunks - every day use questions
rvk:
Here is an explanation from Jeff (on IBX Delphi).
--- Quote ---BufferChunks only tells IBX how much to grow the local buffer size when it needs to grow. The default is 1000 records at a time. This means when you open an IBQuery IBX sets up enough memory to hold 1000 records. When you try to read/insert the 1001st record it will allocate another 1000 records worth of space and move the first 1000 over to that new memory space. This takes time so you will want to minimize the number of times you will probably do this. Smaller BufferChunks size means less wasted memory space on average (if the size is 1000 and your result set is 100 you are wasting 900 records worth of memory). Smaller sizes for larger results sets means slightly slower (in some situations much slower) memory resizing. For instance is you set it to 100 and you are reading 50,000 records you will have to resize 5000 times instead of 500 for a buffer size of 1000.
--- End quote ---
wp:
--- Quote from: Nicole on November 02, 2022, 11:04:33 am ---I have a problem with a TAChart. About 12 fields every day, back for decades.
--- End quote ---
Do you use the TDBChartSource to access IBX? This is a bad idea because this type of chart source is very general and thus has to query the same data from the dataset again and again. Use it only once to fetch all data, and then copy the TDBChartSource into a TListChartSource which is connected to the series. Didn't we have this discussion already?
Thaddy:
--- Quote from: rvk on November 02, 2022, 10:17:00 am ---It's not buffer size we are talking about here but BufferChunks.
--- End quote ---
In this case your invention of size versus chuck does not help: it should still be a power of two for maximum efficiency. Using IBX does not help anyway.
Use a proper database backend so your customers can use it over multiple platforms. AND can maintain it.... >:D >:D >:D
rvk:
--- Quote from: Thaddy on November 02, 2022, 12:04:10 pm ---
--- Quote from: rvk on November 02, 2022, 10:17:00 am ---It's not buffer size we are talking about here but BufferChunks.
--- End quote ---
In this case your invention of size versus chuck does not help: it should still be a power of two for maximum efficiency. Using IBX does not help anyway.
Use a proper database backend so your customers can use it over multiple platforms. AND can maintain it.... >:D >:D >:D
--- End quote ---
Firebird and IBX is maintained (and can be used on multiple platforms).
So quit your FB bashing. We know you don't like it. It's getting boring.
And size is different from chunks.
1000 chunks of 32 bytes record size is still a power of 2 sorry, dividable by 2, which is fine in this situation. You really don't need to set it at 16.384.
Thaddy:
Yes I know you know and for good reasons that I explained many times.
BTW dividable by two is NOT a single shift operation so it is definitely more costly than a power of two..
Using a niche database is simply unacceptable since it is always about the DATA and access to it under most circumstances and most languages.
IBX does not fit that purpose, maintained or unmaintained, either way.
Navigation
[0] Message Index
[#] Next page
[*] Previous page