> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.funnelflux.pro/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# Show names instead of IDs in reports with Data Mapping

A lot of traffic sources only pass IDs in their tracking links.

So your reports end up full of values like `sh243df-2dk34s-abl592` in the campaign column, and you have to keep the traffic source's dashboard open next to FunnelFlux to know which campaign that actually is.

**Data Mapping** fixes that. You give us a simple CSV of IDs and names, and we show the names in reporting instead.

It's best to think of it as a lookup table that sits on the traffic source. Nothing in your tracking links or stored data changes -- we only swap the label when you view a report.

 This is analogous to the dictionary sync feature available for integrations. It's also mutually exclusive. You can't use this feature if you've linked an integration for your traffic source + enabled dictionary sync on it.

## When to use it

If your traffic source has a native integration with **Enable ID to name sync**, use that instead. We pull the names from the platform automatically, see [Dictionary Sync](https://help.funnelflux.pro/en/article/using-traffic-source-integrations-s4p02b/).

Data Mapping is for everything else: push, pop and native networks, or any source where you can export a list of campaign (or zone, creative, etc.) IDs with their names.

The two are either/or per traffic source. While ID to name sync is on, the Data Mapping section on that traffic source is switched off and shows:

> Names for this traffic source come from the integration's dictionary sync, so manual data mapping is off.

## Step 1: Choose what to map on the traffic source

Open the traffic source > **Advanced Settings** tab > **Data Mapping** section.

![Data Mapping section of the traffic source Advanced Settings tab](https://storage.crisp.chat/users/helpdesk/website/-/b/7/4/9/b749232d828ce800/01-traffic-source-data-mapping_p70veh.png)

1. Turn on **Map names for this traffic source** `[1]`.
2. Tick **Campaign** `[2]` to map the values in the reserved `campaign` tracking field.
3. Tick **Field 1** `[3]` and pick one of your custom tracking fields to map a second value, e.g. a zone ID or creative ID. **Field 2** works the same way if you need a third. Field 1 and Field 2 can't point at the same tracking field.
4. Optionally tick **Show the ID after each mapped name** `[4]`. Reports then show `Name (ID)` rather than just the name -- handy if you still need the raw ID to search for it in the traffic source.
5. Save the traffic source.

Note that you upload the actual names on a separate page, after saving. The traffic source only decides WHICH fields get names.

The Field 1 / Field 2 lists show your custom tracking fields with the name you gave each one on the **Tracking Fields** tab, e.g. `C1 - adid`. So make sure the ID you want named is actually captured in one of your custom tracking fields.

## Step 2: Upload your names

Go to **Data Updates > Data Mapping** and pick the traffic source.

You'll see a table with Campaign, Field 1 and Field 2 (with the tracking field each one uses in brackets), whether name mapping is enabled for each on that traffic source, and the actions for it.

![Data Mapping page with a traffic source selected](https://storage.crisp.chat/users/helpdesk/website/-/b/7/4/9/b749232d828ce800/02-data-mapping-page_za2mdj.png)

1. Pick the traffic source `[1]`.
2. Prepare your CSV. It needs a header row with an `id` column and a `name` column -- click **Download sample CSV** `[2]` if you want a starting point. Any other columns are ignored, so an export from your traffic source with the two columns renamed works fine.
3. Click **Upload CSV** `[3]` on the field you want to fill and choose the file.
4. Check the message under the table, e.g. "Names uploaded for Campaign: 120 added, 4 updated."

"Added" is IDs we didn't have a name for yet, "updated" is IDs that already had one and now get the name from your file.

An upload merges with what's already there. IDs that aren't in your file keep their current name, so you can upload just your new campaigns each week rather than the full list.

A few limits to know:

- At most 10,000 rows and 4 MiB per upload. For bigger lists, split the file and upload each part.
- IDs and names can each be up to 512 characters.
- Within one file, IDs are matched ignoring case, so `ABC` and `abc` count as the same ID.

### If the upload is rejected

First we check the file itself. If it's missing the `id` or `name` column, we tell you which one and don't send anything:

![Upload refused because the file has no id column](https://storage.crisp.chat/users/helpdesk/website/-/b/7/4/9/b749232d828ce800/03-upload-rejected_ofn1ku.png)

After that, an upload is all-or-nothing. If ANY row has a problem, nothing is saved, and the page lists every bad row with its row number and the problem.

Row numbers count the data rows under the header, and blank lines are skipped.

The usual culprits are an empty ID or name, or the same ID listed twice with different names. The same ID twice with the SAME name is fine -- we just count it once.

Fix the rows and upload the whole file again.

If the page says the upload "could not be confirmed", it's safe to upload the same file again. Re-uploading identical names changes nothing.

## How names show in reports

Names show up for the campaign field and the custom tracking fields you mapped, when your report is broken down by traffic source or filtered to that single traffic source.

That condition exists because the same ID can mean different things on different traffic sources. Campaign `123` on one network has nothing to do with campaign `123` on another, so we need to know which traffic source's names to use.

A few things that work as you'd expect, but are worth knowing:

- Any value without an uploaded name just shows the raw value as before.
- Only the label changes. Row counts and every metric are identical with or without names.
- Names are stored per mapping field (Campaign, Field 1, Field 2), not per tracking field. If you later point Field 1 at a different tracking field, the names you uploaded for Field 1 apply to that new tracking field straight away. The traffic source form warns you when this happens and links to the Data Mapping page in case you want to clear them first.
- If you untick a field or switch mapping off, reports go back to raw values. The names stay stored, so switching it back on shows them again with no new upload.

## Clearing names

On **Data Updates > Data Mapping**, each field has a **Clear existing data** button, and there's a **Clear all existing mapping data for this traffic source** button below the table.

Both ask you to confirm, and only ever affect that one traffic source. Clearing all also removes names stored for fields you've since unticked.

Use this when an upload put the wrong names in. Otherwise you usually don't need it -- uploading a corrected name for an ID replaces the old one.

Names that come from an integration's ID to name sync are never touched by Data Mapping.

## Doing this via the API

If you'd rather automate uploads, e.g. a nightly job that pushes new campaign names from your traffic source, the same upload and clear actions are available through our API. See the [Data Mapping guide](https://api-docs.funnelflux.pro/data-mapping) in the API docs.