This is probably a question for an NCBI E-utils person rather then the Rentrez wrapper writer or this community but I'm struggling to find enough info.
I'm trying to assemble a set of metadata for sequences deposited in Nuccore with Feature:Source /country=New Zealand, starting with the big list of IDs returned using a general query for 'New Zealand' (as it doesn't seem possible to query the feature table directly). For that I need use_history=TRUE and step through the large set of results using the list stored on the history server. However, if I subsequently use the web_history object I don't get the expected return data set.
To simplify, here is a E-util web query which returns a single nuccore record ...
If I use Rentrez and the history server then something like ...
seq_NZ <- entrez_search(db = "nuccore", term=
"new+zealand AND ddbj_embl_genbank[filter] AND gerhardtia+pseudosaponacea[Organism]"
, retmax=0, use_history=TRUE)
Then if I use the web history object to fetch the record...
seqrecs <- entrez_fetch(db="nuccore", web_history=seq_NZ$web_history,rettype="xml", retmax=1, parsed=TRUE)
I get back what looks like the associated popset of records and not the single record (for the single queried ID) I was expecting. What silly simple thing am I doing wrong?