---
schema_version: "1"
id: d76b99cf2b9797860b1e0e0986551cc62f5870b3cb7627576ad86ab51672d26e
title: LensField
collection: tableau
version: next
locale: en-us
portal_url: https://docs.salesforce.com/tableau/next/en-us/api/metadata_api/reference/lensfield.doc.md
canonical_url: https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/lensfield.doc.html
source_site: help.tableau.com
content_type: documentation
content_hash: 946e8989c985ddbc8ae2c3178f4c6444dcca05e2a402d3fc6d1ca0443502adb6
---
_menu_ Types

OBJECT

# LensField

Lens Fields contain extra information based on an underlying datasource field

## [_link_](#graphql-schema-definition) GraphQL Schema definition

`   - type LensField {  - # Unique identifier used by the metadata API. Not the same as the numeric ID used - # on server - id: [ID](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/id.doc.html)!  - # Name of field shown locally in Ask Data. If null or empty, use name inherited - # from datasource field. - name: [String](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/string.doc.html)  - # Description of field shown in Ask Data. If null or empty, use description - # inherited from datasource field. - description: [String](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/string.doc.html)  - # Underlying datasource field this lens field is based on - datasourceField: [Field](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/field.doc.html)!  - # The Lens which contains this lens field - containingLens: [Lens](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/lens.doc.html) - }   `

## [_link_](#require-by) Require by

- [AnalyticsField_Base GraphQL type for a field containing analytics metadata_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/analyticsfield.doc.html "AnalyticsField - Base GraphQL type for a field containing analytics metadata")

- [BinField_GraphQL type for a binned continuous measure field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/calculations\_bins.html_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/binfield.doc.html "BinField - GraphQL type for a binned continuous measure field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/calculations_bins.html")

- [CalculatedField_GraphQL type for a calculated field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/calculations\_calculatedfields.html_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/calculatedfield.doc.html "CalculatedField - GraphQL type for a calculated field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/calculations_calculatedfields.html")

- [ColumnField_ColumnFields are a type of field which directly connects to a column in some type of table._](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/columnfield.doc.html "ColumnField - ColumnFields are a type of field which directly connects to a column in some type of table.")

- [CombinedField_GraphQL type for a combined field. Combined fields concatanate fields together into one string._](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/combinedfield.doc.html "CombinedField - GraphQL type for a combined field. Combined fields concatanate fields together into one string.")

- [CombinedSetField_GraphQL type for a combined set field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/sortgroup\_sets\_create.html#Combine_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/combinedsetfield.doc.html "CombinedSetField - GraphQL type for a combined set field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/sortgroup_sets_create.html#Combine")

- [DataField_Base GraphQL type for a field containing data. Most types of Fields will implement this interface with exceptions like HierarchyField._](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/datafield.doc.html "DataField - Base GraphQL type for a field containing data. Most types of Fields will implement this interface with exceptions like HierarchyField.")

- [DatasourceField_GraphQL type for a data source field. Data source fields can only exist in embedded data sources which connect to a published data source. A data source field is an embedded data source's 'layered' representation of a field that already exists in the published data source and is mostly a copy of the field in the published data source. Data source fields can get their own descriptions and renames local to the embedded data source, but cannot otherwise be modified in the embedded data source._](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/datasourcefield.doc.html "DatasourceField - GraphQL type for a data source field. Data source fields can only exist in embedded data sources which connect to a published data source. A data source field is an embedded data source's 'layered' representation of a field that already exists in the published data source and is mostly a copy of the field in the published data source. Data source fields can get their own descriptions and renames local to the embedded data source, but cannot otherwise be modified in the embedded data source.")

- [Field_Base GraphQL type for a field_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/field.doc.html "Field - Base GraphQL type for a field")

- [FieldReferencingField_Base GraphQL type for a field that references another field. For example, a CalculatedField can reference a ColumnField in its formula._](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/fieldreferencingfield.doc.html "FieldReferencingField - Base GraphQL type for a field that references another field. For example, a CalculatedField can reference a ColumnField in its formula.")

- [GroupField_GraphQL type for a group field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/sortgroup\_groups\_creating.html_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/groupfield.doc.html "GroupField - GraphQL type for a group field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/sortgroup_groups_creating.html")

- [HierarchyField_GraphQL type for a hierarchy. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/qs\_hierarchies.html_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/hierarchyfield.doc.html "HierarchyField - GraphQL type for a hierarchy. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/qs_hierarchies.html")

- [Lens_Lenses are curated, embeddable Ask Data experiences. \*Introduced in Tableau Cloud June 2022 / Server 2022.3.\* \*Retired in Tableau Cloud February 2024 / Server 2024.2.\*_](lens.doc.html "Lens - Lenses are curated, embeddable Ask Data experiences.  
    *Introduced in Tableau Cloud June 2022 / Server 2022.3.*  
    *Retired in Tableau Cloud February 2024 / Server 2024.2.*")

- [LensFieldsConnection_Connection Type for LensField_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/lensfieldsconnection.doc.html "LensFieldsConnection - Connection Type for LensField")

- [Query_Query root for Metadata GraphQL interface_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/query.doc.html "Query - Query root for Metadata GraphQL interface")

- [SetField_GraphQL type for a set field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/sortgroup\_sets\_create.html_](https://help.tableau.com/v0.0/api/metadata_api/en-us/reference/setfield.doc.html "SetField - GraphQL type for a set field. See https://onlinehelp.tableau.com/current/pro/desktop/en-us/sortgroup_sets_create.html")