Discussions
NSC | Retrieve Rows from Transaction Table for a Specific Record Types
The transaction table is shared by all transaction types including purchase orders, vendor bills, sales orders, item fulfillments, and more. Retrieving all of them at once could cause performance issues and thus it is common for companies with large amounts of data to break this table down into several queries. One way to narrow it down is by specifying the record type of the transactions, as shown in the sample below.
SELECT id AS internalID, tranid as docNum, trandate, type, trandisplayname
FROMtransaction
WHERE recordtype='invoice'OR recordtype = 'salesorder'
The sample code described herein is provided on an "as is" basis, without warranty of any kind, to the fullest extent permitted by law. Oracle + NetSuite Inc. does not warrant or guarantee the individual success developers may have in implementing the sample code on their development platforms or in using their own Web server configurations.
Refer a Member to the Community | Earn the Answer Accepter Badge | Vote for the contents you'd like to see