Tagged: bin search
This topic contains 4 replies, has 1 voice, and was last updated by Budi Keren 7 years ago.
-
AuthorPosts
-
December 15, 2016 at 2:16 pm #6538
mlab_elmo_solTechnologies used: Web Services (Suite Talk), C#.
I am doing an ItemSearchBasic to find an InventoryItem. The record I want is returned but I can see in the database that some fields (ex: costingMethod) have values (ex: standard) that I cannot retrieve using that search. The costingMethodSpecified is false when I get the search result. Is there a way to specify the list of fields that I want to retrieve with my search? Can I specify that I want all fields to be retrieve from the database?
This is a cached copy. Click here to see the original post. -
December 15, 2016 at 7:34 pm #6539
tect22Hi mlab_elmo_ssol,
For fields like costingMethod, its more likely you need a initialization of a RecordRef to pull out the “Standard” value, as when you run your C# Application you will only get the record type and record internalid from the CostingMethod field.
Regards,
Hector
-
December 16, 2016 at 6:35 am #6540
mlab_elmo_solHi,
The field costingMethod in objet InventoryItem is an enumeration that is defined like this:
enum ItemCostingMethod { _average, _fifo, _lifo, _lotNumbered, _serialized, _standard }
This field is not a reference to another field (i.e. not a RecordRef). From the documentation of NetSuite, I can see that a basic search should return everything in the record read (complete information but slower to read) and an advanced search returns only the specified fields (incomplete information but quicker to get).
I am using a basic search so I am supposed to get the complete information contained in the target record/object. I tried a basic search with different InventoryItems objects that have different values in their costingMethod field (like _standard or _fifo) but I always get a costingMethod which value is _average (=0, the default value for integer/enum) and costingMethodSpecified is always false.
I do not understand the reason of this behavior and how I can obtain that information (costingMethod) as well as many other fields in that object (InventoryItem) or other object types.
Thank you.
Michel
-
December 16, 2016 at 10:46 am #6541
tect22Hi Michel,
Nice, you are correct, I thought that was a simple RecordRef, thanks for enlightening me.
-
November 8, 2017 at 9:22 am #16406
I am having the same problem but with a Bins saved search. In the UI the column for Location shows the text name of the location. But, when you execute the saved search in webservices the location field returns the Internal Id. I don’t want the Internal Id, I want the text as shown in the UI. Any idea on how to get the text and not the Internal ID? Here is the xml request:
<soap:Envelope xmlns:xsd=”http://www.w3.org/2001/XMLSchema” xmlns:soap=”http://schemas.xmlsoap.org/soap/envelope/” xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”>
<soap:Header>
<applicationInfo xmlns=”urn:messages_2015_2.platform.webservices.ne tsuite.com”>
<applicationId>*********************************** *</applicationId>
</applicationInfo>
<searchPreferences xmlns=”urn:messages_2015_2.platform.webservices.ne tsuite.com”>
<bodyFieldsOnly>false</bodyFieldsOnly>
</searchPreferences>
</soap:Header>
<soap:Body>
<search xmlns=”urn:messages_2015_2.platform.webservices.ne tsuite.com”>
<searchRecord savedSearchId=”3633″ xsi:type=”q1:BinSearchAdvanced” xmlns:q1=”urn:accounting_2015_2.lists.webservices. netsuite.com”/>
</search>
</soap:Body>
</soap:Envelope>And the xml Response (notice that the internal ID of “20” is returned and not the actual location text name):
<platformCore:searchRow xsi:type=”listAcct:BinSearchRow” xmlns:listAcct=”urn:accounting_2015_2.lists.webser vices.netsuite.com”>
<listAcct:basic xmlnslatformCommon=”urn:common_2015_2.platform.webservi ces.netsuite.com”>
<platformCommon:binNumber>
<platformCore:searchValue>BinA1</platformCore:searchValue>
</platformCommon:binNumber>
<platformCommon:internalId>
<platformCore:searchValue internalId=”2460″/>
</platformCommon:internalId>
<platformCommon:location>
<platformCore:searchValue>20</platformCore:searchValue>
</platformCommon:location>
</listAcct:basic>
</platformCore:searchRow>And the xml Response (notice that the internal ID of “20” is returned and not the actual location text name):
BinA120
Any help would be much appreciated! Thanks.
- This reply was modified 7 years ago by Budi Keren.
- This reply was modified 7 years ago by Budi Keren.
-
AuthorPosts
You must be logged in to reply to this topic.