NetSuite: Difference between revisions

From Starfish ETL
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
== Headline text ==
= Connection String Parameters =
= Connection String Parameters =


Line 43: Line 46:
End Function
End Function
</source>
</source>
== Headline text ==

Revision as of 20:36, 1 December 2015

Headline text

Connection String Parameters

AccountId: Required (Number) The Account ID for your Netsuite organization. You can retrieve this number in NetSuite, in the Integration section under Setup.

LogoutUnknownSessions: (Boolean) If you cannot log in because it's complaining there is already an active session, try using this session to force those other sessions to be invalidated.

MaximumConcurrentSessions: (Number) If you wish to use multithreading while writing to NetSuite, you must use this setting. By default, NetSuite does not support mutltithreading. This only becomes available if you have purchased and activated the SuiteCloud Plus license for NetSuite. This will give you the ability to use up to 10 concurrent sessions. If you wish to use 10 threads, then set this parameter to 10, and also use 10 as the value in the Thread Count property on the Run Job tab in Starfish. Using multithreading with NetSuite will greatly improve the speed of writing. If you have to move a large amount of data, we highly recommend acquiring this license.

AggregateColumnMode: (String - available options below) Aggregate columns are the columns that will appear on base tables which aggregate all of the data contained within child collections (such as Address)

    [Ignore]: All aggregate will be ignored and will not show up as available colums in the table definition. 
    [List]: Aggregate columns will be listed in all tables, but on base tables such as SalesOrders, they will not retrieve data from NetSuite.  
    [ListAndRetrieve]: Aggregate columns will be listed and requested on all tables. When reading data from NetSuite this can significantly slow down requests.

Netsuite Metadata Folder: (String) If you get a certain error, it may be necessary to supply a folder where Starfish can temporarily store metadata retrieved from Netsuite. This allows the metadata to be downloaded a cached to help speed up future requests. Recommended to create a "Metadata" folder under StarfishEngine to ensure proper permissions. Default full suggested path would therefore be: C:\Inetpub\wwwroot\StarfishEngine\Metadata. The Metadata folder will not be created automatically. When first setting this parameter, you'll have to create this folder manually.

RoleId: (Number) The RoleId is the InternalId of the role that will be used to log in to NetSuite. If you do not enter this, it will use the user's default role. Useful for forcing Administrator role in certain scenarios.

UseSandbox: (Boolean) Set to true if you would like to use the sandbox instance of your NetSuite account.


Picklists

When writing to NetSuite Picklist fields, you cannot write the value of the picklist to the field. You must instead reference the Internal Id of the picklist value you wish to use. These can be obtained in the Customization section under Setup. Using a hand-built Xref list for large lists would be recommended practice.


Aggregate Fields (Addresses)

When writing addresses to NetSuite, you must use the AggregateColumnMode=List so that the AddressbookListAggregate Column will be available to map to. Address data must be supplied as a chunk of XML containing the complete address record. See below as an example.

Function ScriptedField
	dim xml
	xml = "<Customer_AddressbookList>"
	xml = xml & "<Row>"
	xml = xml & "<AddressbookList_DefaultShipping>true</AddressbookList_DefaultShipping>"
	xml = xml & "<AddressbookList_DefaultBilling>true</AddressbookList_DefaultBilling>"
	xml = xml & "<AddressbookList_Label>Address</AddressbookList_Label>"
	xml = xml & "<AddressbookList_addressee>@@ORG:Name@@</AddressbookList_addressee>"
	xml = xml & "<AddressbookList_Addr1>@@ORG:ShippingStreet@@</AddressbookList_Addr1>"
	xml = xml & "<AddressbookList_City>@@ORG:ShippingCity@@</AddressbookList_City>"
	xml = xml & "<AddressbookList_Zip>@@ORG:ShippingPostalCode@@</AddressbookList_Zip>"
	xml = xml & "<AddressbookList_State>@@ORG:ShippingState@@</AddressbookList_State>"
	xml = xml & "<AddressbookList_Country>@@ORG:ShippingCountry@@</AddressbookList_Country>"
	xml = xml & "</Row></Customer_AddressbookList>"
	ScriptedField=xml
End Function


Headline text