https://netsuiteprofessionals.com logo
#suitescript
Title
# suitescript
s

screnshaw

04/21/2022, 3:39 PM
If I'm on a customer and do getValue("shipcountry") it returns "US". How can I take that value and get countries id so that I can use it on a search
d

dcrsmith

04/21/2022, 4:17 PM
Use the N/query to get it.
You probably want the
uniquekey
from this result
Copy code
var result = query.runSuiteQL({
    query:"SELECT * from country where id = ?"
    ,params:["US"]
}).asMappedResults();
❤️ 1
s

screnshaw

04/25/2022, 3:01 PM
That's awesome.