How can I put each line item property into its own column?

The field line_items.properties is typically used to capture additional custom options or personalization data from the customer for each product/line item in the order.

Selecting this field in the app will export all of them combined in 1 column in JSON format.

If you need to place them in separate columns, we have function called search_attributes(data, property_name) you can use for this purpose.

For example, let's say you have Line Item Property called "Birthday" that you want to include in your report as a separate column.

To do so, in the Calculated Fields section of the Data Settings of an Order data export, simply use this formula:

search_attributes({{ line_items.properties }}, "Birthday")

If you have other properties you'd like to place into their own columns, simply repeat the formula above in additional Calculated Fields and replace "Birthday" with the name of the other properties.

Here's a screenshot of what this looks like in the app:

EZ Exporter - Calculated Fields Formula fo Exporting Shopify Line Item Properties

You can find the name of each line item property from the Shopify Admin's order detail page as shown below:

Shopify Admin - Order Detail - Line Item Properties

Using the search_attributes() formula for each of the line item property will output something like this:

Shopify CSV Export of Individual Line Item Properties from an Order

Also see our blog post for more info.


Related Articles:


App: EZ Exporter

Tags: faq, line item properties, advanced features