ElsevierDev / elsapy

A Python module for use with Elsevier's APIs: Scopus, ScienceDirect, others.
http://api.elsevier.com
BSD 3-Clause "New" or "Revised" License
366 stars 144 forks source link

Sciencedirect Querys not working #51

Open janfelixklein opened 4 years ago

janfelixklein commented 4 years ago

Hello, I'm trying to make some ScienceDirect work, e.g:

doc_srch = ElsSearch(tak(renal failure),'sciencedirect')

or

doc_srch = ElsSearch(title-abstr-key(renal failure),'sciencedirect')

as described in the Science Direct Search Tips `

The Error says that the query cannot be translated: {"service-error":{"status":{"statusCode":"INVALID_INPUT","statusText":"Unable to translate query provided. Error=[The search contained no translatable search terms. EmptyQueryException - No translatable query terms found in field.]"}}}`

Any suggestions on this?

rvdinter commented 4 years ago

I'm having the same issue, is there any solution yet? I know that boolean search works for Scopus though.

ipekdk commented 3 years ago

I guess noone from developer team is looking at these issues tab. :/

YHOYO commented 1 year ago

title-abstr-key(renal failure) IS INCORRECT

THE RIGHT WAY IS title-abs-key(renal failure)

search = ElsSearch('title-abs-key(renal failure)', 'scopus')

gabListon commented 9 months ago

That works for Scopus, but the problem here is with ScienceDirect.

Other fields worked fine on ScienceDirect, but I''m also having trouble with this one. Neither 'title-abs-key', 'title-abstr-key' or 'tak' worked and I'm unaware of another way of writing this field, at least not one that is included in the guides.

search = ElsSearch('title-abs-key(renal failure)', 'sciencedirect')

Altough those are returning this error:

requests.exceptions.HTTPError: HTTP 400 Error from https://api.elsevier.com/content/search/sciencedirect?query=tak%28renal+failure%29 and using headers {'X-ELS-APIKey': '---', 'User-Agent': 'elsapy-v0.5.1', 'Accept': 'application/json', 'X-ELS-Insttoken': '---'}:
{"service-error":{"status":{"statusCode":"INVALID_INPUT","statusText":"Unable to translate query provided. Error=[The search contained no translatable search terms. EmptyQueryException - No translatable query terms found in field.]"}}}

Which is different from when I put a random word in the field name:


requests.exceptions.HTTPError: HTTP 400 Error from https://api.elsevier.com/content/search/sciencedirect?query=takkkkkk%28renal+failure%29 and using headers {'X-ELS-APIKey': '---', 'User-Agent': 'elsapy-v0.5.1', 'Accept': 'application/json', 'X-ELS-Insttoken': '---'}:
{"service-error":{"status":{"statusCode":"INVALID_INPUT","statusText":"Unable to translate query provided. Error=[Bad Field!]"}}}
``