News (2017-09-10): New application bib2gls for use with glossaries-extra.sty.

# Bug Tracker

ID 15 Closed (fixed) datatool 2.11 N/A DTLgetvalueforkey fails when key=0

## Report

Thank you for datatool!; it has revolutionized my workflow.

Please see the attached MWE.. pdflatex output looks like:

5.045455
Undefined Value
23.227273
32.318182
41.409091


### MWE

\documentclass[11pt,letterpaper]{article}

\usepackage{filecontents}
\begin{filecontents*}{data.out}
LOGDISTANCE,distance,barnum
-1,0.100000,5.045455
0,1.000000,14.136364
1,10.000000,23.227273
2,100.000000,32.318182
3,1000.000000,41.409091
4,10000.000000,50.500000
\end{filecontents*}

\usepackage{datatool}

\listfiles

\begin{document}

\DTLgetvalueforkey\Onekm{barnum}{MyDBase}{LOGDISTANCE}{-1} \Onekm

\DTLgetvalueforkey\Onekm{barnum}{MyDBase}{LOGDISTANCE}{0} \Onekm

\DTLgetvalueforkey\Onekm{barnum}{MyDBase}{LOGDISTANCE}{1} \Onekm

\DTLgetvalueforkey\Onekm{barnum}{MyDBase}{LOGDISTANCE}{2} \Onekm

\DTLgetvalueforkey\Onekm{barnum}{MyDBase}{LOGDISTANCE}{3} \Onekm

\end{document}


Comment from OP
Date: 2013-03-15 00:45:29 CDT

Thanks!

## Evaluation

The test for null was incorrectly interpreting 0 as a null value. Fixed in v2.13 (2013-01-15).

## Watch This Report

If you would like to add a comment regarding this bug report, please fill in the form below, but don't use it for a different bug or feature request, even if it's related. Instead fill out a new bug report or feature request. (If you want to link it to this report, make a note of the ID number at the top of the page.)

 Name (Optional) Comment You can use the following markup: [pre]Displayed verbatim[/pre] [tt]monospace font[/tt] [url]web address[/url] which will be converted to:
Displayed verbatim