MongoDB Date fields nested objects

defining date fields is a cool option of mongodb node.
but how to use, if we have date fields within nested objects?
i tried to define nested objects dot notated i.e.: customer.created_at
but this doesn’t seem to work on nested objects.
maybe nested object date fields are not implemented within the current code or i’m doing it the wrong way?
for main objects on first level, date fields are formated as expected.

my example mongodb node looks like this:

{
  "nodes": [
    {
      "parameters": {
        "operation": "insert",
        "collection": "orders",
        "fields": "id,admin_graphql_api_id,app_id,browser_ip,buyer_accepts_marketing,cancel_reason,cancelled_at,cart_token,checkout_id,checkout_token,client_details,closed_at,confirmed,contact_email,created_at,currency,current_subtotal_price,current_subtotal_price_set,current_total_discounts,current_total_discounts_set,current_total_duties_set,current_total_price,current_total_price_set,current_total_tax,current_total_tax_set,customer_locale,device_id,discount_codes,email,financial_status,fulfillment_status,gateway,landing_site,landing_site_ref,location_id,name,note,note_attributes,number,order_number,order_status_url,original_total_duties_set,payment_gateway_names,phone,presentment_currency,processed_at,processing_method,reference,referring_site,source_identifier,source_name,source_url,subtotal_price,subtotal_price_set,tags,tax_lines,taxes_included,test,token,total_discounts,total_discounts_set,total_line_items_price,total_line_items_price_set,total_outstanding,total_price,total_price_set,total_price_usd,total_shipping_price_set,total_tax,total_tax_set,total_tip_received,total_weight,updated_at,user_id,billing_address,customer,discount_applications,fulfillments,line_items,refunds,shipping_address,shipping_lines",
        "options": {
          "dateFields": "=cancelled_at,closed_at,created_at,processed_at,updated_at,customer.created_at,customer.updated_at,customer.accepts_marketing_updated_at"
        }
      },
      "name": "MongoDB",
      "type": "n8n-nodes-base.mongoDb",
      "typeVersion": 1,
      "position": [
        880,
        290
      ],
      "credentials": {
        "mongoDb": "mongodb-connection-test"
      }
    }
  ],
  "connections": {}
}

has anyone a hint for me?

Welcome to the community @MaxF

Yes, sadly, it does not support dot notation. It should not be difficult to add. I just added it to my to-do.

1 Like

Ok dot notation in the date field got added. Can you please test it locally and confirm it works for you?

1 Like

thank’s for your fast response!
i’ll wait for the updated version.
:slight_smile: