General ⇒ Datatool : automatically add a new entry
Datatool : automatically add a new entry
1) I would like concatenate prénom (name) and nom (surname) to create a new user name without an accent on letters, like this: Avogadro-Amedeo.
It works, see my post below
2) How can i automatically add a new entry and complete each row.
I tried \dtlupdateentryincurrentrow{\dtlcol}{stuff}, \dtlupdateentryincurrentrow.
It works, see my post below
3) Is it possible that this new entry could be a command ? My idea is not clear yet.
It works, see my post below
Many thanks for help
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
Datatool : automatically add a new entry
second & third step step : fail
If my file is :
Code: Select all
key1,key2,key3,key4
Amédéo,AVogadro,,
Bohr,Niels,,
Code: Select all
key1,key2,key3,key4
Amédéo,AVogadro,Stuff1,Stuffa
Bohr,Niels,Stuff2,Stuffb
I would like to use a command, like this
Code: Select all
\DTLforeachkey{}{
add a new entry in the column X with \command{argument1}{argument2}
}
Sorry for my bad English.
- Attachments
-
- ListeCompetencesEleves.csv
- (371 Bytes) Downloaded 227 times
-
- Tests-Competence-5-forum.tex
- (3.5 KiB) Downloaded 234 times
Datatool : automatically add a new entry
Code: Select all
\DTLforeach{ListeCompetencesEleves}{%
%\dtlexpandnewvalue%
\nom=nom,\prenom=prénom}%
{%
\DTLforeachkeyinrow{\ItemLu}{%
\ifthenelse{\dtlcol>2 \and \dtlcol <\nombredecolonnes}{\DTLreplaceentryforrow{\dtlkey}{value}}%%%%
{\relax}%
}%
}%