Bug Tracker RSS feed

ID 301🔗
Date: 2025-04-03 09:46:31
Last update: 2025-04-03 12:41:15
Status Closed (Fixed)
Category datatool
Version 3.3
Summary Strings containing <string> <number> E <number> <string> break parser

Return to Search Results

Sign in to subscribe to notifications about this report.

Description

In v3.3, \DTLread breaks when reading a CSV file with option csv-content=literal, in case a string field contains a substring matching [0-9]+E[0-9]+ (that is: a sequence of digits with an 'E' in the middle).

I suspect that the type checker erroneously tries to consider the entry as a fp number written in scientific notation, and fails.


Minimal working example:

\documentclass{article}

\begin{filecontents}[overwrite]{test_db.csv}
Col1
AAA11E33
\end{filecontents}

\usepackage{datatool}

\DTLread[name={mydb},format=csv, csv-content=literal]{test_db.csv}

\begin{document}
We never reach this point
\end{document}
Error:
! Use of \??? doesn't match its definition.
<argument> \???
! LaTeX Error: Unknown fp word AAA.

MWE

Download (254B)

\documentclass{article}

\begin{filecontents}[overwrite]{test_db.csv}
Col1
AAA11E33
\end{filecontents}

\usepackage{datatool}

\DTLread[name={mydb},format=csv, csv-content=literal]{test_db.csv}%

\begin{document}
We never reach this point.
\end{document}

Evaluation

Yes, you're right. The regular expression needs to be anchored. I'll get that fixed.

Update: fixed in v3.4. Allow a few days for it to reach your TeX distribution.

Comments

0 comments.


Add Comment

Name (optional):

Are you human? Please confirm the bug report ID (which can be found at the top of this page) or login if you have an account. All guest comments have to be manually checked before they appear on the page. There are too many bots trying to spam the site to allow unauthenticated users to post without verification.

Comment:


You can use the following markup:

Block:

[pre]Displayed verbatim[/pre]
[quote]block quote[/quote]

In line:

[tt]code[/tt]
[file]file/package/class name[/file]
[em]emphasized text[/em]
[b]bold text[/b]
[url]web address[/url] [sup]superscript[/sup]
[sub]subscript[/sub]

Ordered list:
[ol]
[li]first item[/li]
[li]second item[/li]
[/ol]

Unordered list:
[ul]
[li]first item[/li]
[li]second item[/li]
[/ul]

You can use the Preview button to review your message formatting before submitting.

Page permalink: https://www.dickimaw-books.com/bugtracker.php?key=301

Return to Search Results