Re: Out of memory during "large" request
- From: jseger@xxxxxxxxx (Jeffrey Seger)
- Date: Tue, 21 Nov 2006 05:23:54 -0500
I'm very curious as to how this line evaluates. It suggests that
perhaps the query is being re-prepared with different criteria each
time through? Would it be possible to describe what's going on there
as I am thinking that (maybe) the same thing could be accomplished
through the use of placeholders.
Also, how are you processing the results? Are you shoving the whole
thing into one big array or are you processing each row and then
reusing the variables? Depending on the number of rows being
returned, shoving them all into an array can very quickly chew up all
of your available mmory.
WHERE vista.id_sello_editorial_web = '$id_sello_editorial_web'
$cad_query_colecciones $cad_query_listar
On 11/21/06, Juan Carlos García <juancarg@xxxxxxxx> wrote:
At 09:25 21/11/2006, Juan Carlos García wrote:
>At 00:16 21/11/2006, you wrote:
>
>>post the relevant code.....including how you are going about
>>preparing, executing and fetching the data.
>
>This is my programs's code:
>
> $consulta=qq{
>SELECT vista.anio_publicacion,vista.autores_lista_precios,
>
>vista.eci_cdu,vista.eci_bisac,vista.eci_desc_ruta,vista.lprecios_desc_ruta,
> vista.codigo_comercial,vista.codigo_proyecto,vista.codigo_barras,
> vista.comentario_lista_precios,
> vista.desc_sello_ruta_img,vista.edicion,vista.formato_encuad_paginas,
> vista.indice,vista.isbn,vista.iva,vista.marcar_pa_nov_rdc,vista.obrcod,
>
>TRIM(TO_CHAR(pw_utilidades_precios.f_precio_con_iva_prd(vista.obrcod,
>TO_DATE('15/11/2006')),'990D99')) precio_euros,
>
>TRIM(TO_CHAR(pw_utilidades_precios.f_precio_sin_iva_prd(vista.obrcod,
>TO_DATE('15/11/2006')),'990D99')) precio_euros_sin_iva,
> vista.resena,vista.resena_catalogo,vista.id_sello_editorial_web,
>
>vista.subtitulo,vista.titulo,vista.titulo_str,vista.titulo_indice,vista.titulo_indice_str,vista.orden_c,
> vista.peso,vista.complementos
>FROM extr_lprecios_v vista $tabla_cl_productos
>WHERE vista.id_sello_editorial_web =
>'$id_sello_editorial_web' $cad_query_colecciones $cad_query_listar
>ORDER BY $ordenacion};
>
> $cur21= $dbh->prepare($consulta);
> $cur21->execute();
> while (($anio_publicacion,$autores_lista_precios,
> $eci_cdu,$eci_bisac,$eci_desc_ruta,$lprecios_desc_ruta,
> $codigo_comercial,$codigo_proyecto,$codigo_ean,
> $comentario_lista_precios,
> $desc_sello_ruta_img,$edicion,$formato_encuad_paginas,
> $indice,$isbn,$iva,$marcar_pa_nov_rdc,$obrcod,
> $precio_euros,$precio_euros_sin_iva,
> $resena,$resena_catalogo,$id_sello_mostrar,
>
>$subtitulo,$titulo,$titulo_str,$titulo_indice,$titulo_indice_str,$orden_c,
> $peso,$complementos)=$cur21->fetchrow)
>
>where
>
>$consulta is a variable to contain the query.
>extr_lprecios_v is the view from where I obtain the information.
>$tabla_cl_productos is a variable where I put a
>table name. My program build the query
>dynamically and sometimes I need this table.
>$cad_query_colecciones and $cad_query_listar
>contain the conditions for the JOIN between the
>view and the table in $tabla_cl_productos and
>some conditions to filter the regs in this last table.
>$ordenacion contains the conditions for ORDER BY sentence.
>
>Thats all. I hope that this information was useful.
>Thanks again.
--
--------------------------------------------------------------------------------------------------------------
The darkest places in hell are reserved for those who maintain their
neutrality in times of moral crisis.
Dante Alighieri (1265 - 1321)
They who would give up an essential liberty for temporary security,
deserve neither liberty or security.
Benjamin Franklin
Our lives begin to end the day we become silent about things that matter.
Martin Luther King
The right of the people to be secure in their persons, houses, papers,
and effects, against unreasonable searches and seizures, shall not be
violated, and no warrants shall issue, but upon probable cause,
supported by oath or affirmation, and particularly describing the
place to be searched, and the persons or things to be seized.
Amendment IV to the Constitution of the United States
--------------------------------------------------------------------------------------------------------------
.
- References:
- Out of memory during "large" request
- From: juancarg
- Re: Out of memory during "large" request
- From: juancarg
- Out of memory during "large" request
- Prev by Date: Re: How should I connect via DBD::Oracle to efficiently obtain 2000+ simultaneous connections?
- Next by Date: Another (free) db schema drawing tool (for Oracle): Schemester
- Previous by thread: Re: Out of memory during "large" request
- Next by thread: Re: Out of memory during "large" request
- Index(es):
Relevant Pages
|
|