Alvaro, creo que la propuesta es clara: Permitir que se pueda escoger cuales 
columnas del archivo se pueden cargar, algo similar a esto:

Can one skip certain columns while loading data?
One cannot use POSITION(x:y) with delimited data. Luckily, from Oracle 8i one 
can specify FILLER columns. FILLER columns are used to skip columns/fields in 
the load 
file, ignoring fields that one does not want. Look at this example: 
LOAD DATA
TRUNCATE INTO TABLE T1
FIELDS TERMINATED BY ','
( field1, field2 FILLER, field3
) 
BOUNDFILLER (available with Oracle 9i and above) can be used if the skipped 
column's value will be required later again. Here is an example: 
LOAD DATA
INFILE *
TRUNCATE INTO TABLE sometable
FIELDS TERMINATED BY ","  trailing nullcols
( c1, field2 BOUNDFILLER, field3 BOUNDFILLER, field4 BOUNDFILLER, field5 
BOUNDFILLER, c2     ":field2 || :field3", c3     ":field4 + :field5"
) 
Tomado de:http://www.orafaq.com/wiki/SQL*Loader_FAQ

Muchas gracias


>________________________________
> De: Alvaro Herrera <alvhe...@alvh.no-ip.org>
>Para: Daymel Bonne Solís <dbo...@uci.cu> 
>CC: Sergio Valdes Hurtado <svh.pg...@gmail.com>; Ayuda 
><pgsql-es-ayuda@postgresql.org> 
>Enviado: Miércoles 16 de Mayo de 2012 16:09
>Asunto: Re: [pgsql-es-ayuda] Re: [pgsql-es-ayuda] Re: [pgsql-es-ayuda] 
>Efectuar copy desde un archivo con más columnas que la tabla
> 
>
>Excerpts from Daymel Bonne Sol铆s's message of mi茅 may 16 16:59:28 -0400 2012:
>> El 16/05/12 16:33, Daymel Bonne Sol铆s escribi贸:
>
>> > Lamentablemente es as铆. Creo que ah铆 se puede mejorar, porque es un 
>> > escenario bastante com煤n. Que opinan al respecto?
>> 
>> Revisando la documentaci贸n, encontr茅 que lo dice claramente:
>> 
>> " (...) COPY FROM will raise an error if any line of the input file 
>> contains more or fewer columns than are expected. (...) ".
>
>... lo cual no quiere decir que no pueda cambiarse.  Pero si vas a
>proponer algo, tiene que ser algo 煤til en general.  驴Cu谩l era tu
>propuesta?
>
>-- 
>脕lvaro Herrera <alvhe...@alvh.no-ip.org>
>-
>Enviado a la lista de correo pgsql-es-ayuda (pgsql-es-ayuda@postgresql.org)
>Para cambiar tu suscripci髇:
>http://www.postgresql.org/mailpref/pgsql-es-ayuda
>
>
>

Responder a