Forum |  HardWare.fr | News | Articles | PC | S'identifier | S'inscrire | Shop Recherche
1296 connectés 

  FORUM HardWare.fr
  Programmation
  SQL/NoSQL

  DB2 : load

 


 Mot :   Pseudo :  
 
Bas de page
Auteur Sujet :

DB2 : load

n°1677835
incinerato​r
Posté le 28-01-2008 à 12:47:37  profilanswer
 

Bonjour,
 
J'essaie d'exécuter la commande suivante :
 
load  from d:\TEST1.txt OF ASC
modified by dateformat="DD/MM/YYYY" packeddecimal binarynumerics nullindchar=?
reclen=66
method L (
  1 4 ,
  5 5 ,
  6 55 ,
  56 65 ,
  66 66
)
null indicators (
  0,
  0,
  0,
  0,
  0
)
insert into DDACPRTU.DDAPPL0T copy no;
 
Contenue du FICHIER TEST1 :
 
"AEXA","1","A.T.E.X.A. (ACCIDENT TRAVAIL EXPLOITANT AGRICOLE) ",08/04/2002,"A""ANUA","1","ANNUAIRE
        ",01/01/2003,"A""COMM","1","ENSEMBLE DES APPLICATIONS COMMUNES                ",22/05/2002,"A""FIPA","1","FICHIER IDENTIFICA
TION POPULATION AGRICOLE        ",01/01/2002,"A""NDCO","1","DICTIONNAIRE DE DONNEES GENERALES                 ",25/05/2003,"A""PARC"
,"1","PLATEFORME COMMUNE D'ACCES AUX REPERTOIRES        ",21/02/2005,"A""SARA","1","S.A.R.A
  ",13/01/2003,"A"

 
Mais je rencontre les messages suivants :
 
SQL3500W  The utility is beginning the "LOAD" phase at time "2008-01-28  
12.27.02.724823".
 
SQL3519W  Begin Load Consistency Point. Input record count = "0".
 
SQL3520W  Load Consistency Point was successful.
 
SQL3191N  The field in row "F0-1", column "56" which begins with "ICOLE) ",0"  
does not match the user specified DATEFORMAT, TIMEFORMAT, or TIMESTAMPFORMAT.  
The row will be rejected.
 
SQL3185W  The previous error occurred while processing data from row "F0-1" of  
the input file.
 
SQL3191N  The field in row "F0-2", column "56" which begins with "A""COMM",""  
does not match the user specified DATEFORMAT, TIMEFORMAT, or TIMESTAMPFORMAT.  
The row will be rejected.
 
SQL3185W  The previous error occurred while processing data from row "F0-2" of  
the input file.
 
SQL3191N  The field in row "F0-4", column "56" which begins with "OLE       "  
does not match the user specified DATEFORMAT, TIMEFORMAT, or TIMESTAMPFORMAT.  
The row will be rejected.
 
SQL3185W  The previous error occurred while processing data from row "F0-4" of  
the input file.
 
SQL3191N  The field in row "F0-5", column "56" which begins with "ERALES    "  
does not match the user specified DATEFORMAT, TIMEFORMAT, or TIMESTAMPFORMAT.  
The row will be rejected.
 
SQL3185W  The previous error occurred while processing data from row "F0-5" of  
the input file.
 
SQL3191N  The field in row "F0-6", column "56" which begins with "MUNE D'ACC"  
does not match the user specified DATEFORMAT, TIMEFORMAT, or TIMESTAMPFORMAT.  
The row will be rejected.
 
SQL3185W  The previous error occurred while processing data from row "F0-6" of  
the input file.
 
SQL3191N  The field in row "F0-7", column "56" which begins with "A.R.A   ","  
does not match the user specified DATEFORMAT, TIMEFORMAT, or TIMESTAMPFORMAT.  
The row will be rejected.
 
SQL3185W  The previous error occurred while processing data from row "F0-7" of  
the input file.
 
SQL3137W  Row "8" is too short.  At least one input value being loaded to a  
non-nullable column is missing.  The row was not loaded.
 
SQL3185W  The previous error occurred while processing data from row "F0-8" of  
the input file.
 
SQL3227W  Record token "F0-1" refers to user record number "1".
 
SQL3227W  Record token "F0-2" refers to user record number "2".
 
SQL3227W  Record token "F0-4" refers to user record number "4".
 
SQL3227W  Record token "F0-5" refers to user record number "5".
 
SQL3227W  Record token "F0-6" refers to user record number "6".
 
SQL3227W  Record token "F0-7" refers to user record number "7".
 
SQL3227W  Record token "F0-8" refers to user record number "8".
 
SQL3110N  The utility has completed processing.  "8" rows were read from the  
input file.
 
SQL3519W  Begin Load Consistency Point. Input record count = "8".
 
SQL3520W  Load Consistency Point was successful.
 
SQL3515W  The utility has finished the "LOAD" phase at time "2008-01-28  
12.27.02.757870".
 
SQL3500W  The utility is beginning the "BUILD" phase at time "2008-01-28  
12.27.02.759154".
 
SQL3213I  The indexing mode is "REBUILD".
 
SQL3515W  The utility has finished the "BUILD" phase at time "2008-01-28  
12.27.02.852219".
 
SQL3500W  The utility is beginning the "DELETE" phase at time "2008-01-28  
12.27.02.891513".
 
SQL3509W  The utility has deleted "1" rows from the table.
 
SQL3515W  The utility has finished the "DELETE" phase at time "2008-01-28  
12.27.02.894687".
 
SQL3107W  There is at least one warning message in the message file.
 
 
Number of rows read         = 8
Number of rows skipped      = 0
Number of rows loaded       = 1
Number of rows rejected     = 7
Number of rows deleted      = 1
Number of rows committed    = 8

 
Merci de m'aider sur ce sujet.

mood
Publicité
Posté le 28-01-2008 à 12:47:37  profilanswer
 

n°1677845
casimimir
Posté le 28-01-2008 à 13:28:37  profilanswer
 

tu as un décalage dans tes champs, manifestement il s'attend a trouver une date a un endroit ou  tu lui fournis de l'alpha,  
truc bizarre dans ton fichier: "A""ANUA" non séparé par une virgule

n°1678137
incinerato​r
Posté le 28-01-2008 à 18:24:43  profilanswer
 

Merci bcp pour votre réponse toute fois j'ai pu régler le premier problème mais malheureusement j'ai rencontrer un autre voir ci-dessous :
 
Le fichier UKcp est sous le format suivante :
 
AEXA1A.T.E.X.A. (ACCIDENT TRAVAIL EXPLOITANT AGRICOLE) 2002-04-08AANUA1ANNUAIRE                                          2003-01-01ACOMM1ENSEMBLE DES APPLICATIONS COMMUNES                2002-05-22AFIPA1FICHIER IDENTIFICATION POPULATION AGRICOLE        2002-01-01ANDCO1DICTIONNAIRE DE DONNEES GENERALES                 2003-05-25APARC1PLATEFORME COMMUNE D'ACCES AUX REPERTOIRES        2005-02-21ASARA1S.A.R.A                                           2003-01-13A
 
quand j'essaie d'exécuter la comande suivante il me rejet un enregistrement le 8éme sachant que le fichier contient seulement 7 enregistrement de taille 66 :
 
load  from d:\UKcp OF ASC
modified by packeddecimal binarynumerics nullindchar=?
reclen=66
method L (
  1 4 ,
  5 5 ,
  6 55 ,
  56 65 ,
  66 66
)
null indicators (
  0,
  0,
  0,
  0,
  0
)
insert into DDACPRTU.DDAPPL0T copy no;
 
Erreur :
-------
SQL3500W  The utility is beginning the "LOAD" phase at time "2008-01-28  
17.59.10.958141".
 
SQL3519W  Begin Load Consistency Point. Input record count = "0".
 
SQL3520W  Load Consistency Point was successful.
 
SQL3137W  Row "8" is too short.  At least one input value being loaded to a  
non-nullable column is missing.  The row was not loaded.
 
SQL3185W  The previous error occurred while processing data from row "F0-8" of  
the input file.
 
SQL3227W  Record token "F0-8" refers to user record number "8".
 
SQL3110N  The utility has completed processing.  "8" rows were read from the  
input file.
 
SQL3519W  Begin Load Consistency Point. Input record count = "8".
 
SQL3520W  Load Consistency Point was successful.
 
SQL3515W  The utility has finished the "LOAD" phase at time "2008-01-28  
17.59.10.978517".
 
SQL3500W  The utility is beginning the "BUILD" phase at time "2008-01-28  
17.59.10.979564".
 
SQL3213I  The indexing mode is "INCREMENTAL".
 
SQL3515W  The utility has finished the "BUILD" phase at time "2008-01-28  
17.59.11.016727".
 
SQL3500W  The utility is beginning the "DELETE" phase at time "2008-01-28  
17.59.11.042350".
 
SQL3509W  The utility has deleted "7" rows from the table.
 
SQL3515W  The utility has finished the "DELETE" phase at time "2008-01-28  
17.59.11.060547".
 
SQL3107W  There is at least one warning message in the message file.
 
 
Number of rows read         = 8
Number of rows skipped      = 0
Number of rows loaded       = 7
Number of rows rejected     = 1
Number of rows deleted      = 7
Number of rows committed    = 8

n°1678138
anapajari
s/travail/glanding on hfr/gs;
Posté le 28-01-2008 à 18:26:07  profilanswer
 

un retour à la ligne de trop à la fin de ton fichier?

n°1678143
incinerato​r
Posté le 28-01-2008 à 18:34:40  profilanswer
 

est comment puis-je enlever le retour à la ligne via l'editeur vi ?

n°1678147
anapajari
s/travail/glanding on hfr/gs;
Posté le 28-01-2008 à 18:59:05  profilanswer
 

dd

n°1678346
incinerato​r
Posté le 29-01-2008 à 10:45:29  profilanswer
 

Merci bcp pour votre réponse mais en utilisant dd je n'ai pas pu supprimer le retour à la ligne.
La méthode que j'ai utilisé est la suivante :  
awk '{ printf $0}' test1 > test2  
Là je suis sure qu’avec printf j'aurai pas de retour à la ligne.


Aller à :
Ajouter une réponse
  FORUM HardWare.fr
  Programmation
  SQL/NoSQL

  DB2 : load

 

Sujets relatifs
DB2 : UrgentDB2 et Materliased Query Table et rollback segment
tablespaces d'un schéma en DB2DB2
[DB2] extraire un nombre packé d'un CHARFenêtre generées "load" "save" automatiquement en pythonQT # Resolu #
[RESOLU] Load data local infileInsertion partielle avec LOAD DATA INFILE (MySQL)
timestamp à insérer dans DB2Synchro AS400 DB2 --> MySQL
Plus de sujets relatifs à : DB2 : load


Copyright © 1997-2022 Hardware.fr SARL (Signaler un contenu illicite / Données personnelles) / Groupe LDLC / Shop HFR