This function returns the number of rows in the specified Data Extension.

NOTE: This function will not return row counts from the System Data Views.



Ordinal Type Required Description
1 String True Data Extension from which to retrieve a row count


Data Extension: LoyaltyMembers

Name Data Type Length Primary Key Nullable Default Value
EmailAddress EmailAddress 254 N N
SubscriberKey Text 254 Y N
FirstName Text 50 N Y
LastName Text 50 N Y
Created Date N Y Current Date

The LoyaltyMembers Data Extension includes these rows:

EmailAddress SubscriberKey FirstName LastName Created
[email protected] 8473 Doug Smith 2017-10-21 12:01
[email protected] 5497 Suzy Jackson 2017-10-20 11:01
[email protected] 7114 Dale Cameron 2017-10-19 10:01

Here is an example utilizing the preceding context:


var @rowCount
set @rowCount  = DataExtensionRowCount("LoyaltyMembers")

rowCount: %%=v(@rowCount)=%%


RowCount: 3