Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL Copy from

Status
Not open for further replies.
Apr 20, 2000
41
US
Copy from command

Hello, I'm trying to copy a selection of records from a non-oracle database (Sybase sql anywhere)to a oracle 7.3.4 table.

Does my source and destination tables have to have the exact same field and attributes? Or can I just copy from a few of the fields.

I get the cpy0005: source and destination col attributes don't match

As in....

COPY from abc/xxxx@odbc:LGT_SRV32 -
APPEND vehicle_import -
using -
SELECT Null LOAD, -
lib_fournisseur DOC_ID, -
Null DOC_SEQ, -
vehicule VEHTYP_CODE, -
'TC' trn_code, -
Null STATUS, -
Null SUPPLIER_VEHICLE_ID, -
Null REFTYP_CODE, -
Null DATE_SHIPPED, -
Null DAYS_UNTIL_ARRIVAL, -
Null DATE_RECEIVED, -
DATE_p1 DATE_SCALED, -
Null EST_MOISTURE, -
POIDS_P1 SITE_GROSS_WEIGHT, -
POIDS_P2 SITE_TARE_WEIGHT, -
'KG' SITE_WEIGHT_UNITS, -
Null SUPPLIER_GROSS_WEIGHT, -
Null SUPPLIER_TARE_WEIGHT, -
Null SUPPLIER_WEIGHT_UNITS, -
Null SITE_TOTAL_PACKING_WEIGHT, -
Null SUPPLIER_TOTAL_PACKING_WT, -
numero SCALE_TICKET_NUMBER, -
bille MANIFEST_NUMBER, -
bag PKG_TYPE1_QUANTITY, -
palette PKG_TYPE2_QUANTITY, -
drum PKG_TYPE3_QUANTITY, -
flowbin PKG_TYPE4_QUANTITY, -
boxes PKG_TYPE5_QUANTITY, -
Null PKG_TYPE6_QUANTITY, -
Null PKG_TYPE7_QUANTITY, -
Null PKG_TYPE8_QUANTITY, -
Null PKG_TYPE9_QUANTITY, -
Null PKG_TYPE10_QUANTITY, -
Null LOAD_STATUS, -
Null LOAD_ERRORS, -
Null VIM_ID, -
'Truck Scale' created_by , -
TODAY(*) creation_date , -
Null LAST_UPDATED_BY, -
Null LAST_UPDATED_DATE -
FROM pesees -
WHERE date_p2 = today(*) -1 and lib_societe = 'CUSTOM MATERIALS' and poidsnet > 0





 
Could it be the data formats don't match?

Try doing a to_date on the data columns and force it into the oracle way of doing things.

We've had that when reading from DB2
 
Could it be the date formats don't match?

Try doing a to_date on the data columns and force it into the oracle way of doing things.

We've had that when reading from DB2
 
Could it be the date formats don't match?

Try doing a to_date on the date columns and force it into the oracle way of doing things.

We've had that when reading from DB2
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top