Page 1 of 1

Throwing exception: APT_BadAlloc: Heap allocation failed.

Posted: Wed May 08, 2019 7:49 pm
by Naren12345babu
ETL job is using ODBC stage to extract .DBF file.

I am getting below error

Throwing exception: APT_BadAlloc: Heap allocation failed.

I tried checking other threads , but did not get much help

Please help here.

Re: Throwing exception: APT_BadAlloc: Heap allocation failed

Posted: Mon May 13, 2019 12:03 pm
by mouthou
Heap allocation is a generic error related to buffering and memory allocation. Not much direct answer for this error as the job needs to be completely checked. But to begin with, are you getting this issue when using ODBC stage only? Can you try replacing it with some other stage as source and check for now? It helps to isolate the insufficient DB settings interrupting with DS operations.

Since you seem to be extracting a database file, volume of records fetched is also in question. Can you give a simple pic of job design to see how big the job is?

Posted: Tue May 14, 2019 2:58 pm
by ray.wurlod
How wide are the rows? There are default maxima that can be overridden with parameters MAXFETCHBUFF and MAXFETCHCOLS in the uvodbc.config file.

Re: Throwing exception: APT_BadAlloc: Heap allocation failed

Posted: Tue Jun 18, 2019 2:05 am
by Naren12345babu
What are the other stages I can use to extract data from DBT files.
Also, I checked for number of bytes per block size, and i got "ODBC_Connector_0,0: Current heap size: 6071520 bytes in 19603 blocks".

Hope this is help ful.

Any idea how to move furhter? what are the other stages that can be used to extract DBT files.

Posted: Tue Jun 18, 2019 7:01 am
by Naren12345babu
Ray, I cannot use uvodbc.config as the configuration seems to be very different where I am working , all values from uvodbc are not present in odbc. Infact when I check uvodbc file, I see only one ODBC connection. but could not get an update.

I also see that columns with ntext are causing this issue.

are there any environment variables that can be used here.

Posted: Thu Jun 20, 2019 6:10 am
by Naren12345babu
Ray, can you provide me syntax of using these paramters in uvodbc.config

Posted: Thu Jun 20, 2019 6:47 am
by Naren12345babu
the datatypes is ntext

Posted: Thu Jun 20, 2019 10:04 am
by chulett
You're not the first person here wondering about things like that.

Suggestion: take one of those values like MAXFETCHBUFF and use it in an exact search here, then go through the results. Right now that one finds 37 other posts that include it. I would start with the resolved ones first but people don't always mark their topics so don't restrict yourself to just those.