Hey there! I am new to Suite QL and trying to lea...
# suiteql
u
Hey there! I am new to Suite QL and trying to learn how to use it. I have a custom record that id like to get data from. Im planing on having a dynamic filter so that when i pass in the value I can use the WHERE to filter down based on that value. so here is the current query
Copy code
var q = "SELECT vas.id, vas.name, vas.custrecord_customer";
     q +=  " FROM customrecord_scr AS vas";
     q +=  " WHERE vas.custrecord_customer = '9546'";
The custrecord_customer is a list record of type customer. right now i just want to get the records where custrecord_customer = ‘9546’. What am i doing wrong ? this query returns 0 results. (this is coming from suitecommerce web service so i cant use ES6 syntax) TIA
c
Just do a select * on it without a where clause, to check the data
u
yea - so taking out the where will return all 3000 + records
and i can see on the lines Json data lines , “custrecord_customer” : “9546" …
c
Yes. I’m saying to look at the data and check that the row you need satisfies the where clause
j
try taking out the quote marks?