SharpSync
  • Welcome
  • Fundamentals
    • Getting Started
      • Registration
      • Landing Page
      • Support
      • Subscription
    • Data Sources
    • Property Mappings
      • Adding Property Mapping
      • Property Mapping Settings
    • Rules
      • Import / Export
        • Append text
        • Calculate number
        • Export manipulation
        • Format as decimal number
        • Prepend text
        • Remove property
        • Replace all instances
        • Replace first instance
        • Round to nearest X
        • Select from JSON
        • Set cell value
        • Set empty cells
        • Text manipulation
      • Display
        • Number between
        • Text contains
        • Text ends with
        • Text evaluation
        • Text is a number
        • Text is exactly
        • Text is in list
        • Text is not a number
        • Text is not empty
        • Text is not in list
        • Text length between
        • Text length is exactly
        • Text maximum length
        • Text minimum length
        • Text not contains
        • Text not ends with
        • Text not starts with
        • Text starts with
      • Advanced Scripting
    • BOM Comparison
    • Data Safety
    • Troubleshooting
      • Duplicate component paths
      • OAuth 2.0
  • Data Sources
    • Autodesk Inventor
    • CSV
      • Getting Started
      • Importing a Bill of Materials (BOM)
    • MS Dynamics 365 Business Central
      • Getting Started
      • Item Fields Json & Internal Names
      • Resource Fields Json & Internal Names
      • List Names For nestedObject Mappings
    • NetSuite
      • OAuth Setup
        • Permissions
      • RESTlet Script Setup
        • SharpSync RESTlet Script
      • Thumbnail Folder Setup
      • Authentication + Configuration
      • Common setup
        • Configure quantity mapping
        • Configure accounts mappings
        • Configure itemType mapping
        • Configure isPhantom mapping
        • Configure subsidiary mapping
        • Configure price mapping
        • Configure Where Used Link mapping
        • Configure thumbnail mapping
        • Read-Only NetSuite Fields
        • Common Mapping Rules
        • Common List names
      • Advanced Bill of Materials
      • Configure Routings
      • Integration tips
      • Troubleshooting
    • Odoo
      • Getting Started
        • Authentication + Configuration
        • Debugging tips
      • Common Setup
        • Map BOM Codes
        • Map BOM Types
        • Map Attribute Values
          • Reading Attributes - Overview
          • Display All Attribute Names
          • Display Single Attribute Values
          • Writing attributes
      • Product Management
      • Hosting Options
      • List Names
      • Permissions
      • Troubleshooting
    • Onshape
      • Getting Started
      • Setting up Derivatives
    • Propel PLM
      • Getting Started
    • SolidWorks
    • SolidWorks PDM
      • Downloading and installing the add-in
      • Configure the add-in
      • Setting up the Solidworks PDM Web 2
      • Troubleshooting
      • Submitting a BOM for update
  • Advanced
    • Derivatives
  • User management
    • User Management
    • Application Permissions
Powered by GitBook
On this page
  • Import Rules
  • Export Rules
  • Rule explanations
  1. Fundamentals
  2. Rules

Import / Export

Import Rules

Import rules are run when the data is imported from the source. The rule will change the incoming value from the data source. For example, if you have a value from a CSV file that is being imported as 0, you can transform the value using the Text Manipulation rule to change from 0 => 0.0

Example You have a value that is received from the data source as a JSON object, say

 {
   "id": 42,
   "refName" : "Material Name"
 }

You can use the

Select from Json

rule to select the key called refName from this JSON object. The value displayed onscreen will be Material Name

Example

[
{
   "id": 41,
   "refName" : "Material Name 1"
},
{
   "id": 42,
   "refName" : "Material Name 2"
 }
]

You can use the

Select from Json

rule to select the key called [1].refName from this JSON object. The value displayed onscreen will be Material Name 2. The selector [1].refName uses a text string to select the value from the array of values. In this case select the 2nd element (indexes start at 0, so element 1 is the 2nd element in the array of 2 elements), then select the refName key on the element. Nested properties are supported.

Export Rules

Export rules are run when the data is exported from SharpSync when using the Submit BOM button. The rule will change the value sent to the data source. For example, if you have value from a source, say Onshape, that was imported as 0, the displayed onscreen as 0.0, you can transform the value using the Text Manipulation rule to change from 0.0 => 0 so that the value may be accepted by Onshape.

Rule explanations

Below is a comprehensive list of Import/Export Property Mapping Rules. Click a rule to explore it in depth.

Rule name
Type
Description

Import / Export

Adds the specified text to the end of the cell value

Import / Export

Uses the cell value and performs a calculation. The result of the calculation replaces the cell value

Export only

Runs the specified javascript expression when data is exported. Has the ability to remove rowData values

Import / Export

Converts the cell value to a number and adds the specified number of decimals. This does round the number

Import / Export

Adds the specified text to the beginning of the cell value

Export only

Removes the specified property when exporting the data

Import / Export

Replaces all instances of the specified text with the new value

Import / Export

Replaces the first instance of the specified text with the new value

Import / Export

Rounds the number to up or down the nearest specified digit

Import / Export

Converts the cell value from text to a JSON object and returns the value given by the specified key

Import / Export

Sets the cell value to the specified text. Existing text is replaced

Import / Export

Set an empty (any cell that has only whitespace or no value) cell value to the specified text

Import / Export

Manipulates (and returns the result of) the cell value using the given the javascript expression

PreviousRulesNextAppend text

Last updated 4 months ago

Append Text
Calculate number
Export manipulation
Format as decimal
Prepend text
Remove property
Replace all instances
Replace first instance
Round to nearest X
Select from Json
Set cell value
Set empty cells
Text manipulation