screnshaw
07/11/2022, 3:52 PMShawn Talbert
07/11/2022, 4:58 PMnsSearchResult2obj
does so as a configurable argument. though admittedly that's only for n/search, not n/query.Shawn Talbert
07/11/2022, 5:02 PMSandii
07/11/2022, 6:27 PMscrenshaw
07/12/2022, 6:17 PMscrenshaw
07/12/2022, 6:18 PMShawn Talbert
07/12/2022, 6:19 PMscrenshaw
07/12/2022, 6:20 PMShawn Talbert
07/12/2022, 6:22 PMSandii
07/12/2022, 6:22 PMalias
property of each column, and asMappedResults() uses that. I don't know how to do it if using suiteQL syntaxscrenshaw
07/12/2022, 6:22 PMscrenshaw
07/12/2022, 6:22 PMSandii
07/12/2022, 6:23 PMquery.columns
from the query, and settting the alias
property on each column to be whatever you wantscrenshaw
07/12/2022, 6:28 PMSandii
07/12/2022, 6:29 PMscrenshaw
07/12/2022, 6:30 PMSandii
07/12/2022, 6:31 PMscrenshaw
07/12/2022, 6:39 PMSandii
07/12/2022, 6:40 PMQuery.toSuiteQL()
Sandii
07/12/2022, 6:41 PMImportant The resulting SuiteQL query string (contained in the SuiteQL.query property) does not include any aliases you set on query result columns in the original query.Query object. For more information about aliases, see Column.alias.
help pages specifically indicates alias doesnt work in suiteQLShawn Talbert
07/12/2022, 7:06 PMShawn Talbert
07/12/2022, 7:08 PMselect foo as bar from T
will result in objects with a property named bar
rather than foo
Sandii
07/12/2022, 8:05 PMscrenshaw
07/12/2022, 8:43 PMscrenshaw
07/12/2022, 8:46 PM