On Fri, Aug 29, 2008 at 3:11 PM, Jorge Herrera Roures
<[EMAIL PROTECTED]> wrote:
>
> UPDATE recetas_hist
> SET ingredientes = ARRAY ( SELECT cod_ingre, cantidad
> FROM ingredientes_recetas
> WHERE cod_receta = '1'
> )
> WHERE cod_receta = '1';
>
UPDATE recetas_hist
SET ingredientes = (SELECT string_to_array(cod_ingre || ',' ||
cantidad, ',')
FROM ingredientes_recetas
WHERE cod_receta = '1'
)
WHERE cod_receta = '1';
--
Atentamente,
Jaime Casanova
Soporte y capacitación de PostgreSQL
AsesorÃa y desarrollo de sistemas
Guayaquil - Ecuador
Cel. (593) 87171157
--
TIP 9: visita nuestro canal de IRC #postgresql-es en irc.freenode.net