1 pièce(s) jointe(s)
Importer le contenu d'un fichier texte dans un champ table
Bonsoir,
j'ai un fichier texte qui contient les lignes suivantes :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
| .\mysql-bin.000001
.\mysql-bin.000002
.\mysql-bin.000003
.\mysql-bin.000004
.\mysql-bin.000005
.\mysql-bin.000006
.\mysql-bin.000007
.\mysql-bin.000008
.\mysql-bin.000009
.\mysql-bin.000010
.\mysql-bin.000011
.\mysql-bin.000012
.\mysql-bin.000013
.\mysql-bin.000014
.\mysql-bin.000015
.\mysql-bin.000016 |
j'aimerais importer uniquement les lignes avec le format "mysql-bin.0000x"(mysql-bin.000007,...,mysql-bin.000016) dans la colonne1 de la table voici mon code:
Code:
1 2 3 4 5 6 7 8 9 10
| ResLecture est une chaîne=""
IdFichier est un entier
IdFichier = fOuvre("C:\wamp\bin\mysql\mysql5.5.24\data\mysql-bin.index",foLecture)
TANTQUE ResLecture <> EOT
ResLecture = fLitLigne(IdFichier)
TableAjouteLigne(TABLE_Table1,ExtraitChaîne(ResLecture,2,"\"))
FIN
fFerme(IdFichier) |
comme resultat j'obtiens (voir image1)
je pense que la ligne 2 doit être un retour chariot.
comment faire pour avoir toute les lignes de la table remplies par le contenu du fichie texte avec le format "mysql-bin.0000x" ?:(
Importer le contenu d'un fichier texte dans un champ table
Bonjour
le code de hpascal marche,lorsque j'essaie le code de michel.souris j'ai toujours mon même problème
Merçi :ccool:
Importer le contenu d'un fichier texte dans un champ table
salut,
je ne t'avais pas compris ,merci pour ton éclaircissement michel.souris