Re: Out of memory during "large" request



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
--------------------------------------------------------------------------------------------------------------
.



Relevant Pages

  • Re: Mix/Max/Avg Help based on dynamic ranges
    ... Did you enter Biff's formula as an array? ... The query I gave you is dependent on your breaking out the ranges as Biff ... Where Nums are the values to avg based on the head count range. ... deemed optimal for building device profiles based on locn size and device ...
    (microsoft.public.excel.worksheet.functions)
  • Re: Imitating Mail Merge on server
    ... given moment we know which data (in this case, customers) is being worked ... and concantenate each query together. ... loop the array, plug in the current recordset value. ... We have close to fifty tokens that we use in the application correspondence, ...
    (microsoft.public.inetserver.asp.general)
  • Re: Subquery Confusion
    ... Then I got this crazy idea that an Array can only contain a maximum ... number of characters, ... Then I decide that maybe I'm completely wrong with my query, ... it out of Excel VBA and spit it into Microsoft SQL Server Management ...
    (microsoft.public.excel.programming)
  • Re: Form fields array
    ... I see your point about the array being empty.. ... Dim incDays ... for counter=0 to iDays 'iDays are the count of how many days between ... >> not know how many records the query will pull up. ...
    (microsoft.public.inetserver.asp.db)
  • Re: Arrays in Access.
    ... The real question, Randy, would be "What is the compelling reason for moving ... query, the DMAX and DMIN functions, for example... ... And all a LOT easier than filling and sorting an array ... >> need to a) sort your array (bubble sort would be efficient, ...
    (comp.databases.ms-access)