Could someone explain below error?

InsertData Function is not valid in content. This function is only allowed in a non batch context

I am trying to insert some data into logging Data Extension at the Email send time.

  • Probably cant use the insertData in sends due to performance issues but I would like to be sure
    – jc_mc
    Aug 29, 2019 at 8:39

1 Answer 1


InsertData function does not work in emails.

Inserts a row in a data extension. Returns the number of rows affected. Use this function with landing pages, SMS and MMS messages in MobileConnect, push messages in MobilePush, and messages in GroupConnect.

Use InsertDE instead.

Inserts a row in a data extension with the column values listed in name and value pairs. You can include multiple name and value pairs as necessary. Returns no value. Use this function with email messages at send time only. No value is returned. This function applies to email messages at send time only.

Source: InsertData, InsertDE

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .