Skip to main content

Added v0.5

The PriceFx connector supports reading and writing to/from a PriceFx instance. Product and Customer master/extension tables, data sources, and Company Parameters are supported.

Tabset

Read​

Recipe​

read:
- pricefx:
host: domain.pricefx.com
partition: partition
user: user
password: password
target: Products

# Optional
columns:
- Product Id
- Product Name
source: dataSource # Required for Data Sources or Product/Customer Extensions
criteria:
- fieldName: ColumnName
operator: equals
value: A Value

Function​

from wrangles.connectors import pricefx
df = pricefx.read(
host='example.pricefx.com',
partition='partition',
target='Products',
user='user',
password='password'
)

Parameters​

ParameterRequiredData TypeNotes
host✓strHostname of the server.
partition✓strPriceFx partition.
user✓strThe user to connect as.
password✓strPassword for the specified user.
target✓Products / Product Extensions / Customers / Customer Extensions / Data SourceThe type of data. For Data Sources or Product/Customer Extensions a source must also be provided.
columnslistSpecify which columns to include.
sourcestrIf the data type is a Data Source or Extension, set the specific table.
criteriadictFilter the returned data set.
batch_sizeintQueries are broken into batches for large data sets. Set the size of the batch. If you're having trouble with timeouts, try reducing this. Default 10,000.
order_bystrUses SQL syntax to sort the input.
ifstrA condition that will determine whether the action runs or not as a whole.

Write​

The column names must match the target column names. For master tables either names (e.g. attribute3) or labels may be used.

For Product/Customer extensions, a column called 'name' with the name of the Extension must be included.

Recipe​

write:
- pricefx:
host: domain.pricefx.com
partition: partition
user: user
password: password
target: Products

# Optional
columns:
- sku
- Product Name
- currency
source: table # Required for Data Sources

Function​

from wrangles.connectors import pricefx
pricefx.write(
df,
host='example.pricefx.com',
partition='partition',
target='Products',
user='user',
password='password'
)

Parameters​

ParameterRequiredData TypeNotes
df✓DataFrameFunction only. DataFrame of contents to write to the server. Columns must match the target schema.
host✓strHostname of the server.
partition✓strPriceFx partition.
user✓strThe user to connect as.
password✓strPassword for the specified user.
target✓Products / Product Extensions / Customers / Customer Extensions / Data SourceThe type of data. For Data Sources or Product/Customer Extensions a source must also be provided.
columnslistSpecify which columns to include.
sourcestrRequired for Data Sources. Set the specific table.
order_bystrUses SQL syntax to sort the output.
ifstrA condition that will determine whether the action runs or not as a whole.