Autocomplete and api field suggestions in strings
Issue #913
resolved
Hi,
I have a question, it is possible to implement (or activate if it already exists) autoomplete and api field suggestions when writing queries in strings?
Thank you, Anja
Comments (2)
-
repo owner -
repo owner - changed status to resolved
This was delivered quite a bit back in the form of Apex (and therefore SOQL) language injection. It should kick in automatically for string literals passed to methods that accept a dynamic SOQL query, e.g.,
Database.query()
, and it can be forced using a// language=Apex
line comment immediately above the string literal containing a dynamic query. - Log in to comment
Hi, Anja. Sorry for the delayed response. Right now it's not via auto-completion. However, you can use what is called "hippie completion" to help with this if there are other references to the object and field names in the same source file:
https://www.jetbrains.com/help/idea/auto-completing-code.html#hippie_completion
I'll keep this enhancement request open for first-class auto-completion in string literals, though.