This app template uses Netsuite version 2021.2
or higher as source system. NetSuite has two data model configurations: SuiteTalk and SuiteQL. Both SuiteTalk and SuiteQL schemas are used in this app template and both need to be extracted.
Extraction for the system is done using CData Sync. To set-up the extraction, make sure you have a valid license for CData Sync and have installed CData Sync.
To be able to connect to Netsuite, certain features need to be enabled in Netsuite and a role should be created with the correct access. Furthermore a custom saved search needs to be created in Netsuite.
In NetSuite, go to Setup -> Company -> Enable Features and enable the following in the SuiteCloud tab:
A role should be created for connecting to NetSuite to extract the data. This role must have the permissions that are listed in CData's documentation for their NetSuite connector. Use a naming convention for the role that would be memorable, like CData Extractor
. Create a token for this role to use in the extraction and note down the details.
One of the tables that the app template requires must be created in NetSuite as a custom saved search. The custom saved search titled transaction item change log
utilizes the Line System Notes Fields... in order to bring in line item level changes into the app template. Follow these steps in order to create the necessary saved search in NetSuite:
Go to Lists -> Search -> Saved Searches -> New. Choose Transaction
for the Search Type. Under Search Title type in transaction item change log
.
Line System Notes: Context
. Choose none of and -None-.Under the Results tab, add the following fields:
Field |
---|
Line Unique Key |
Transaction Number |
Line System Notes: Context |
Line System Notes: Date |
Line System Notes: Field |
Line System Notes: New Value |
Line System Notes: Old Value |
Line System Notes: Record |
Line System Notes: Record ID |
Line System Notes: Record Type |
Line System Notes: Role |
Line System Notes: Set by |
Line System Notes: Type |
Department |
Status |
Vendor: Country |
Vendor: Company Name |
Click Save & Run to save the search and look at the results. Take note of the formatting of the Date
field, you will need this when defining the source connection in CData Sync.
A JavaScript file, called search_script.js
, must be added to NetSuite in order for RESTlet Saved Search Queries to work. Follow the steps from the CData documentation to set this up to be able to query the transaction item change log
Saved Search. After following the steps, note down the SearchId, ScriptId, and DeploymentNum. These are necessary to set up the extraction connection for SuiteTalk.
To be able to extract data from NetSuite, two source connections need to be created in CData Sync, one for SuiteTalk and one for SuiteQL.
Date
in your custom saved search is different from the default date format (yyyy-dd-MMThh:mm:ss +offset
), go to the Advanced tab and specify in the Other field the correct format by defining this as the PreferredDateFormats
property. Example: PreferredDateFormats="MM/dd/yyyy h:mm a";
To set up the destination connection, follow the steps as defined in Create a destination connection (Automation Cloud). Note: If you are using Automation Suite, make sure to select AUTOMATION SUITE
as the DELIVERY
option and select the correct version of Automation Suite you are using.
To be able to extract the data from NetSuite, two jobs need to be set up in CData Sync, one using SuiteTalk as source and one using SuiteQL. Both will use the same destination connection.
In the Advanced tab in the Job Settings panel, edit the following settings:
If you are using Automation Suite, set the Destination Schema in the Settings panel on the overview tab. Use the schema name you retrieved when you created the destination connection.
Important: Make sure you edit the Pre-job Event.
CData Sync allows the use of environment variables in order to drive specific extraction logic in each query.
Variable | Description | Comment |
---|---|---|
start_extraction_date | Defines first date for which data will be extracted. | Mandatory |
end_extraction_date | Last date for which data will be extracted. |
Be mindful of choosing a start_extraction_date
that encompasses the data that you want to capture, as orders are the starting point of the order to cash process.
In order to setup the environment variables:
Step | Action |
---|---|
1 | Go to the Events tab in the Job Settings panel of the job you are creating |
2 | Edit the Pre-Job Event section to add the code displayed below after <!-- Code goes here -- > . Do not modify the api:info details that are shown by default. |
3 | Click on Save Changes. |
<!-- Modify environment variables here. -->
<!-- Variable start_extraction_date must be populated.-->
<api:set attr="out.env:start_extraction_date" value="2022-01-01" />
<!-- In case a specific end date is needed, replace the value string with the required date in yyyy-MM-dd format. -->
<!-- i.e api:set attr="out.env:end_extraction_date" value="2024-12-31" -->
<api:set attr="out.env:end_extraction_date" value="[null | now() | todate('yyyy-MM-dd')]" />
<api:push item="out" />
By default, end_extraction_date
will default to today's date. start_extraction_date
must always be populated.
Once the job is correctly setup, go to Task tab, click + Add Tasks, enable the Custom Query option and paste the following queries (each query needs to maintain the semicolon at the end). Make sure you save all changes.
Use the following custom query for SuiteQL when creating the job:
REPLICATE [employee] WITH TruncateTableData = 'True' SELECT [id], [employeetype], [entityid], [title] FROM [employee];
REPLICATE [entity] WITH TruncateTableData = 'True' SELECT [id], [entityid] FROM [entity];
REPLICATE [item] WITH TruncateTableData = 'True' SELECT [id], [fullname] FROM [item];
REPLICATE [location] WITH TruncateTableData = 'True' SELECT [id], [fullname] FROM [location];
REPLICATE [previoustransactionlinelink] WITH TruncateTableData = 'True' SELECT [linktype], [nextdoc], [nextline], [nexttype], [previousdoc], [previousline] FROM [previoustransactionlinelink] WHERE [nexttype] IN ('SalesOrd', 'CustPymt', 'ItemShip', 'Deposit', 'CustInvc', 'RtnAuth', 'CashSale');
REPLICATE [systemnote] WITH TruncateTableData = 'True' SELECT [id], FORMAT([date], 'yyyy-MM-dd hh:mm:ss') as [date], [field], [name], [newvalue], [oldvalue], [record], [recordid], [recordtypeid] FROM [systemnote] WHERE [field] IN ('TRANDOC.KSTATUS', 'TRANLINE.MESTAMOUNT', 'TRANDOC.BPAYMENTHOLD', 'TRANDOC.STRANTYPE', 'TRANLINE.RITEMCOUNT', 'TRANLINE.MAMOUNT', 'TRANDOC.MAMOUNTMAIN', 'TRANLINE.RUNITPRICE', 'TRANDOC.DSHIP', 'CUSTBODY_REPORT_TIMESTAMP', 'TRANDOC.KFORMTEMPLATE') AND ([recordtypeid] = -30) AND (FORMAT([date], 'yyyy-MM-dd') >= '{env:start_extraction_date}') AND (FORMAT([date], 'yyyy-MM-dd') <= '{env:end_extraction_date}');
REPLICATE [term] WITH TruncateTableData = 'True' SELECT [id], [daysuntilexpiry], [daysuntilnetdue], [discountpercent], [name] FROM [term];
REPLICATE [transaction] WITH TruncateTableData = 'True' SELECT [id], [createdby], FORMAT([createddate], 'yyyy-MM-dd hh:mm:ss') as [createddate], [currency], FORMAT([duedate], 'yyyy-MM-dd') as [duedate], [employee], [exchangerate], [status], [terms], [trandisplayname], [type], [voided] FROM [transaction] WHERE [type] IN ('SalesOrd', 'CustPymt', 'ItemShip', 'Deposit', 'CustInvc', 'RtnAuth', 'CashSale') AND ([createddate] >= '{env:start_extraction_date}') AND ([createddate] <= '{env:end_extraction_date}');
REPLICATE [transactionhistory] WITH TruncateTableData = 'True' SELECT [action], FORMAT([datetime], 'yyyy-MM-dd hh:mm:ss') as [datetime], [entity], [internalid], [type], [username] FROM [transactionhistory] WHERE [type] IN ('SalesOrd', 'CustPymt', 'ItemShip', 'Deposit', 'CustInvc', 'RtnAuth', 'CashSale') AND ([datetime] >= '{env:start_extraction_date}') AND ([datetime] <= '{env:end_extraction_date}');
REPLICATE [transactionline] WITH TruncateTableData = 'True' SELECT DISTINCT [uniquekey], TL.[createdfrom], [department], TL.[entity], [inventorylocation], [item], [itemtype], [linesequencenumber], [location], [netamount], [quantity], [subsidiary], [taxline], [transaction], [units] FROM [transactionline] AS TL JOIN [transaction] as T ON TL.[transaction] = t.[id] WHERE [type] IN ('SalesOrd', 'CustPymt', 'ItemShip', 'Deposit', 'CustInvc', 'RtnAuth', 'CashSale');
REPLICATE [unitstypeuom] WITH TruncateTableData = 'True' SELECT [internalid], [unitname] FROM [unitstypeuom];
Make sure that the query for transactionline
works, as it is a custom case where it is joined to the transaction
table in order to filter to only include transaction lines for transactions in the order to cash process.
In the Advanced tab in the Job Settings panel, edit the following settings:
If you are using Automation Suite, set the Destination Schema in the Settings panel on the overview tab. Use the schema name you retrieved when you created the destination connection.
Important: Make sure you edit the Pre-job Event.
CData Sync allows the use of environment variables in order to drive specific extraction logic in each query.
Variable | Description | Comment |
---|---|---|
start_extraction_date | Defines first date for which data will be extracted. | Mandatory |
end_extraction_date | Last date for which data will be extracted. |
Be mindful of choosing a start_extraction_date
that encompasses the data that you want to capture, as orders are the starting point of the order to cash process.
In order to setup the environment variables:
Step | Action |
---|---|
1 | Go to the Events tab in the Job Settings panel of the job you are creating |
2 | Edit the Pre-Job Event section to add the code displayed below after <!-- Code goes here -- > . Do not modify the api:info details that are shown by default. |
3 | Make sure the date format matches the date format of NetSuite as noted down in the system configuration. |
4 | Click on Save Changes. |
<!-- Modify environment variables here. -->
<!-- Variable start_extraction_date must be populated.-->
<api:set attr="out.env:start_extraction_date" value="2022-01-01" />
<!-- In case a specific end date is needed, replace the value string with the required date in yyyy-MM-dd format. -->
<!-- i.e api:set attr="out.env:end_extraction_date" value="2024-12-31" -->
<api:set attr="out.env:end_extraction_date" value="[null | now() | todate('yyyy-MM-dd')]" />
By default, end_extraction_date
will default to today's date. start_extraction_date
must always be populated.
After the data has been successfully loaded, the Process Mining platform needs to start the data ingestion process. This app template uses two different jobs to fetch all the data, both jobs need extra configuration:
Triggering the second job from the first job
Step | Action |
---|---|
1 | Go to the Events tab in the Job Settings panel of the first job |
2 | Edit the Post-Job Event section to add the code displayed below after <!-- Code goes here -- > . Do not modify the api:info details that are shown by default. |
3 | Replace EXTRACTION_JOB_2 with the name of the second job you created. |
4 | Click Save. |
<!-- Start Executing different Job -->
<api:set attr="job.JobName" value="EXTRACTION_JOB_2"/>
<api:set attr="job.ExecutionType" value="Run"/>
<api:set attr="job.WaitForResults" value="true"/>
<api:call op="syncExecuteJob" in="job"/>
Calling the End of Upload API in the second job
Step | Action |
---|---|
1 | Go to the Events tab in the Job Settings panel of the second job. |
2 | Edit the Post-Job Event section to add the code displayed below after <!-- Code goes here -- > . Do not modify the api:info details that are shown by default. |
3 | Fill out the End of Upload API with the value provided. |
4 | In case you need a debugging log for this call, uncomment the two lines provided in the code below and provide a location for the log file. |
5 | Click Save. |
<api:set attr="http.url" value="END_OF_UPLOAD_API"/>
<!-- <api:set attr="http.verbosity" value="5"/> -->
<!-- <api:set attr="http.logfile" value="D:/mydir/cdata_log.txt"/> -->
<api:call op="httpPost" in="http"/>
Once the job is correctly setup, go to Task tab, click + Add Tasks, enable the Custom Query option and paste the following query. Make sure you save all changes. Use the following custom query for SuiteTalk when creating the job:
REPLICATE [transaction_item_change_log] WITH TruncateTableData = 'True' SELECT [Line_Unique_Key], [Transaction_Number], [Context], FORMAT([Date], 'yyyy-MM-dd hh:mm:ss') as [Date], [Field_text] as [Field], [New_Value], [Old_Value], [Record], [Record_ID], [Record_Type], [Role_text] as [Role], [Set_by_text] as [Set_by], [Type], [Department_text] as [Department], [Status_text] as [Status], [Internal_ID_text] as [Internal_ID] FROM [transaction_item_change_log] WHERE (FORMAT([Date], 'yyyy-MM-dd') >= '{env:start_extraction_date}') AND (FORMAT([Date], 'yyyy-MM-dd') <= '{env:end_extraction_date}');
REPLICATE [SalesOrder] WITH TruncateTableData = 'True' SELECT [InternalId], [BillingAddress_Country], [BillingAddress_State], [Department_Name], [Entity_Name], [SalesGroup_Name], [ShippingAddress_Country],[Subsidiary_Name] FROM [SalesOrder];
This section contains an overview of the fields for each of the input tables of the Oracle NetSuite Order-to-Cash app template. For each table the fields are listed. Below is a list of tables that are brought in with the NetSuite SuiteQL Schema specified:
The following is a list of tables that are brought in with the NetSuite SuiteTalk Schema specified:
The transaction_item_change_log
table is a custom saved search that has been created for the purpose of bringing line item change history into the transformations.
More information can be found on these tables in the NetSuite help center. The Analytics Browser tab is for SuiteQL tables.
Field | Data type | Label | Filtering |
---|---|---|---|
id | Text | Internal ID | |
employeetype | Text | Type | |
entityid | Text | Entity ID | |
title | Text | Job Title |
Field | Data type | Label | Filtering |
---|---|---|---|
id | Text | Internal ID | |
entityid | Text | Entity name |
Field | Data type | Label | Filtering |
---|---|---|---|
id | Text | Internal ID | |
fullname | Text | Internal ID |
Field | Data type | Label | Filtering |
---|---|---|---|
id | Text | Internal ID | |
fullname | Text | Full Name |
Field | Data type | Label | Filtering |
---|---|---|---|
linktype | Text | Link Type | |
nextdoc | Text | Transaction ID of next document | |
nextline | Text | Line ID of the next document line | |
nexttype | Text | Next document type | in ('SalesOrd', 'CustPymt', 'ItemShip', 'Deposit', 'CustInvc', 'RtnAuth', 'CashSale') |
previousdoc | Text | Transaction ID of previous document | |
previousline | Text | Line ID of the previous document line |
Field | Data type | Label | Filtering |
---|---|---|---|
id | Text | Internal ID | |
date | Datetime | Date | |
field | Text | Field where systemnote change occurs | in ('TRANDOC.KSTATUS', 'TRANLINE.MESTAMOUNT', 'TRANDOC.BPAYMENTHOLD', 'TRANDOC.STRANTYPE', 'TRANLINE.RITEMCOUNT', 'TRANLINE.MAMOUNT', 'TRANDOC.MAMOUNTMAIN', 'TRANLINE.RUNITPRICE', 'TRANDOC.DSHIP', 'CUSTBODY_REPORT_TIMESTAMP') |
name | Text | Owner internal id | |
newvalue | Text | New value | |
oldvalue | Text | Old value | |
record | Text | Record name | |
recordid | Text | Transaction id | |
recordtypeid | Text | State | -30 |
Field | Data type | Label | Filtering |
---|---|---|---|
id | Text | Internal ID | |
daysuntilexpiry | Integer | Days Till Discount Expires | |
daysuntilnetdue | Integer | Days Till Net Due | |
discountpercent | Double | % Discount | |
name | Text | Terms |
Field | Data type | Label | Filtering |
---|---|---|---|
id | Text | Internal ID | |
createdby | Text | Created By | |
createddate | Datetime | Date Created | |
currency | Text | Currency | |
duedate | Date | Due Date | |
employee | Text | Sales Rep | |
exchangerate | Text | Exchange Rate | |
status | Text | Status | |
terms | Text | Terms | |
trandisplayname | Text | Transaction Name | |
type | Text | Type | in ('SalesOrd', 'CustPymt', 'ItemShip', 'Deposit', 'CustInvc', 'RtnAuth', 'CashSale') |
voided | Boolean | Voided |
Field | Data type | Label | Filtering |
---|---|---|---|
internalid | Text | Transaction ID | |
action | Text | Action | |
datetime | Datetime | Datetime | |
entity | Text | Entity | |
type | Text | Type | in ('SalesOrd', 'CustPymt', 'ItemShip', 'Deposit', 'CustInvc', 'RtnAuth', 'CashSale') |
username | Text | User |
This table is joined to the transaction table in order to filter on transaction."type"
Field | Data type | Label | Filtering |
---|---|---|---|
uniquekey | Text | Unique Key | |
createdfrom | Text | Created From | |
department | Text | Department | |
entity | Text | Entity | |
inventorylocation | Text | Storage location | |
item | Text | Item | |
itemtype | Text | Item Type | |
linesequencenumber | Text | Line Number | |
location | Text | Location | |
netamount | Double | Amount (Net) (Transaction Currency) | |
quantity | Double | Quantity | |
subsidiary | Text | Subsidiary | |
taxline | Text | Tax Line | |
transaction | Text | Transaction ID | |
units | Text | Unit ID |
Field | Data type | Label | Filtering |
---|---|---|---|
internalid | Text | Internal ID | |
unitname | Text | Name of the measuring unit |
Field | Data type | Label | Filtering |
---|---|---|---|
InternalId | Text | Unique ID of the sales order | |
BillingAddress_Country | Text | Billing country of the customer | |
BillingAddress_State | Text | Billing state/region of the customer | |
Department_Name | Text | The display name of the department | |
Entity_Name | Text | The display name of the customer | |
SalesGroup_Name | Text | The display name of the sales group | |
ShippingAddress_Country | Text | Shipping country of the sales order | |
Subsidiary_Name | Text | The display name of the subsidiary |
This is the table created as a custom saved search and connected through the SuiteTalk RESTlet Saved Search Schema.
Field | Data type | Label | Filtering |
---|---|---|---|
Line_Unique_Key | Text | Unique ID of the line item | |
Transaction_Number | Text | Transaction document number | |
Context | Text | Execution context of the change | |
Date | Datetime | Datetime | |
Field | Text | Field of change | |
New_Value | Text | New value | |
Old_Value | Text | Old value | |
Record | Text | Record type | |
Record_ID | Text | Transaction ID | |
Record_Type | Text | One word record type | |
Role | Text | Name of the role making the change | |
Set_by | Text | Name of user making the change | |
Internal_ID | Text | User ID of person making the change | |
Status | Text | Status of the transaction | |
Type | Text | Change log action type | |
Department | Text | Name of the department |
Below is an overview of the objects, and their attributes, of the Oracle NetSuite Order-to-Cash app template.
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Sales order ID | SalesOrder."InternalId" |
Text | Y | The unique identifier of the sales order. |
Company | SalesOrder."Subsidiary_Name" |
Text | N | The company for which the sales order is created. |
Customer | SalesOrder."Entity_Name" |
Text | N | The customer for whom the sales order is created. |
Customer country | SalesOrder."BillingAddress_Country" |
Text | N | The country associated to the customer. |
Customer region | SalesOrder."BillingAddress_State" |
Text | N | The region associated to the customer. |
Distribution channel | attribute |
Text | N | The distribution channel associated to the sales order. |
Division | SalesOrder."Department_Name" |
Text | N | The division associated to the sales order. |
Requested delivery date | attribute |
Date | N | The customer’s requested delivery date for the sales order. |
Sales group | SalesOrder."SalesGroup_Name" |
Text | N | The sales group associated to the sales order. |
Sales office | attribute |
Text | N | The sales office associated to the sales order. |
Sales order type | attribute |
Text | N | The sales order type of the sales order. |
Sales organization | attribute |
Text | N | The sales organization of the sales order. |
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Sales order item ID | transactionline."uniquekey" |
Text | Y | The unique identifier of the sales order item. |
Sales order ID | transactionline."transaction" |
Text | Y | The unique identifier of the sales order. |
Creation date | transaction."createddate |
Date | Y | The date on which the sales order item is created. |
Category | transactionline."itemtype" |
Text | N | The category of sales order item. |
Incoterms | attribute |
Text | N | The incoterms associated to the sales order item. |
Latest expected delivery date | transaction."duedate" |
Date | N | The latest expected delivery date of (parts of) the sales order item. |
Material | items."fullname" |
Text | N | The material sold. |
Material group | transactionline."itemtype" |
Text | N | The categorization of the material sold. |
Payment terms | term."name" |
Text | N | The terms of payment associated to the sales order item. |
Plant | location."fullname" |
Text | N | The plant associated to the sales order item. |
Profit center | attribute |
Text | N | The profit center associated to the sales order item. |
Quantity | concat(abs(transactionlines."Quantity"), ' ', ifnull(unitstypeuom."Unit_name", 'Units')) |
Text | N | The quantity and unit of measurement sold. |
Sales order item | concat(transactions."trandisplayname", '-', transactionlines."lineid") |
Text | N | A user-friendly name to identify the sales order item |
Shipping point country | SalesOrder."ShippingAddress_Country" |
Text | N | The country where the goods are delivered associated to the sales order item. |
Storage location | transactionlines."Inventory_location" |
Text | N | Storage location associated to the sales order item. |
Value | abs(transactionline."netamount" * transaction."exchangerate") |
Double | N | A monetary value related to the sales order item. |
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Delivery ID | transaction."id" |
Text | Y | The unique identifier of the delivery. |
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Delivery item ID | transactionline."uniquekey" |
Text | Y | The unique identifier of the delivery item. |
Delivery ID | transactionline."transaction" |
Text | N* | The unique identifier of the delivery. |
Sales order items ID | transactionline."uniquekey" |
Text | N* | The unique identifier of the sales order item. |
Delivery items is invoiced | attribute |
Boolean | N | Indicates if the sales order item is released to invoicing. |
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Invoice ID | transaction."id" |
Text | Y | The unique identifier of the invoice. |
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Invoice item ID | transactionline."uniquekey" |
Text | Y | The unique identifier of the invoice item. |
Invoice ID | transactionline."transaction" |
Text | N* | The unique identifier of the invoice. |
Delivery item ID | transactionline."uniquekey" |
Text | N* | The unique identifier of the delivery item. |
Invoice item is cancelled | transaction."voided" |
Boolean | N | Indicates if the invoice item is cancelled. |
Invoice item is released into accounting | attribute |
Boolean | N | Indicates if the invoice item is billable. |
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Invoice cancellation ID | transaction."id" |
Text | Y | The unique identifier of the invoice cancellation. |
Invoice ID | transaction."id" |
Text | N* | The unique identifier of the invoice that is cancelled. |
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Accounting document ID | concat(transactionline."transaction", transactionline."createdfrom") |
Text | Y | The unique identifier of the accounting document. |
Invoice ID | transactionline."createdfrom" |
Text | N* | The unique identifier of the invoice. |
Accounting document is cleared | attribute |
Boolean | N | Indicates if the accounting document has been handled and is closed. |
Name | Attribute | Data type | Mandatory Y/N | Description |
---|---|---|---|---|
Payment ID | transaction."id" |
Text | Y | The unique identifier of the payment. |
Accounting document ID | concat(transactionline."transaction", transactionline."createdfrom") |
Text | N* | The unique identifier of the accounting document. |
This identifies the creation action of a sales order.
transactionhistory."action" = 'CREATE' WHERE transactionhistory."context" = 'SalesOrd'
This identifies the deletion action of a sales order.
transactionhistory."action" = 'DELETE' WHERE transactionhistory."context" = 'SalesOrd'
This identifies the creation action of a sales order item.
This identifies a change to the price of a sales order item.
transaction_item_change_log."Field" = 'Amount'
This identifies a change to the quantity of a sales order item.
transaction_item_change_log."Field" = 'Quantity'
This identifies a change to the location of a sales order item.
transaction_item_change_log."Field" = 'Location'
This identifies that a sales order item has been closed or voided.
transaction_item_change_log."Field" = 'Closed'
This identifies the creation action of a delivery.
transactionhistory."action" = 'CREATE' WHERE transactionhistory."context" = 'ItemShip'
This identifies the deletion action of a delivery.
transactionhistory."action" = 'DELETE' WHERE transactionhistory."context" = 'ItemShip'
This identifies that the goods for this delivery have been picked.
systemnote."field" = 'TRANDOC.KSTATUS' and systemnote."newvalue" = 'Picked'
This identifies that the goods for this delivery have been packed.
systemnote."field" = 'TRANDOC.KSTATUS' and systemnote."newvalue" = 'Packed'
This identifies that the goods for this delivery have been shipped.
systemnote."field" = 'TRANDOC.KSTATUS' and systemnote."newvalue" = 'Shipped'
This identifies the creation action of a delivery item.
This identifies a change to the delivery item price.
transaction_item_change_log."Field" = 'Amount'
This identifies a change to the delivery item quantity.
transaction_item_change_log."Field" = 'Quantity'
This identifies a change to the delivery item location.
transaction_item_change_log."Field" = 'Location'
This identifies the creation action of a customer invoice.
transactionhistory."action" = 'CREATE' WHERE transactionhistory."context" = 'CustInvc'
This identifies the deletion action of a customer invoice.
transactionhistory."action" = 'DELETE' WHERE transactionhistory."context" = 'CustInvc'
This identifies the creation action of an invoice item.
This identifies a change to the price of an invoice item.
transaction_item_change_log."Field" = 'Amount'
This identifies a change to the quantity of an invoice item.
transaction_item_change_log."Field" = 'Quantity'
This identifies the cancellation of an invoice.
systemnote."Field" = 'TRANDOC.KSTATUS' and systemnote."New_value" = 'Voided'
This identifies an item return.
transaction_item_change_log."Field" = 'Closed' where transaction_item_change_log."Record_type" = 'returnauthorization'
This identifies payment receipt.
systemnote."field" = 'TRANDOC.KSTATUS' and systemnote."newvalue" = 'Paid In Full'
The model Events_base
, located in the 3_events
directory, is a union of all the outputs from the other models in the 3_events
directory. Each event is unique and corresponds to one ID (i.e. Sales order ID, Sales order item ID, etc.).
This seed file is used to add automation-related properties to each activity, used for the automation potential dashboard. For more information, see Simulating Automation Potential.
Field | Type | Description |
---|---|---|
Activity | Text | Display name for the activity |
Event_cost | Double | Cost associated with the activity |
Event_processing_time | Integer | Processing time associated with the activity (in milliseconds) |
This seed file is used to define properties for the due dates. For more information, see Due Dates.
Field | Type | Description |
---|---|---|
Due_date | Text | The name of the due date |
Due_date_type | Text | The Due date type |
Fixed_costs | Boolean | An indication whether costs are fixed or time based |
Cost | Double | Fixed costs: The amount of costs. Variable costs: The amount of costs per Time and Time_type |
Time | Integer | A number indicating the amount of time in case of time-based costs |
Time_type | Text | Type of time period for cost calculations. This can be any of the following values: day , hour , minute , second or millisecond |
A variable exists in dbt_project.yml
called Automated_users for users to specify the automated users that exist in the Entity table. Please add the entity.id
for these users to this variable.
NetSuite SuiteQL relies on some incredibly large tables for its data, which can be filtered by specifying the record types required. Not filtering on these can cause a lot of performance issues, and will replicate a lot of superfluous data.
If you plan on using CSV files and are going to be using the SQL Query Editor for exporting the SuiteQL tables, the SQL Query Editor tool only allows for up to 5,000 rows to be exported in each query. If more rows are needed, one can filter based on date, and add the results together into a larger file.
Filtering the transactionline table is important, as it can be a rather large table if one does not. However, this requires joining the transactionline and transaction tables in order to filter transactionline to only include the transaction types that are listed in the filtering above. Please use the custom query located in load-from-source
for transactionline in order to filter correctly.
DELETE
activities like Delete sales order or Delete invoice will only appear in the process graph if the case has been deleted after the initial data has been pulled. Deleted orders and invoices will appear in the transactionhistory
table, but will be removed from the transaction
, transactionline
, systemnote
, and transaction_item_change_log
tables.
Void activities are built with NetSuite having Void transactions using reversing disabled. In NetSuite, go to Setup -> Accounting -> Accounting Preferences to check.
The line link between delivery items and invoice items is implied, since they link back to the same sales order item line. Staging models Delivery_invoice_relation
and Invoice_sales_relation
create a rownum to match the delivery item and invoice item, as a sales order item may have multiple deliveries and multiple invoices. This assumes that the first delivery corresponds to the first invoice and so on. If the second delivery is invoiced first, then the relation will be incorrect. We expect this issue to be highly unlikely to occur, but wanted to make users aware of the potentiality.
NetSuite is structurally built around the header level, so tracking item level changes requires utilizing a mixture of SuiteTalk and SuiteQL Schemas to find and pull the requisite data for process mining.
If you encounter errors when running a job that state column not found, go to the Advanced tab of the NetSuite Connection and set the Row Scan Depth: to 0
CData Sync may exhibit some issues in filtering the extraction tables on multiple values, so this is something to keep in mind if you do encounter similar issues.
Some of the input fields of the objects are blank as they are not in the NetSuite system. Sales order type
is an example.