Skip to content

Update AGOL DB view and component tag table to handle missing (null) names #22462

@mddilley

Description

@mddilley

We have a bug where component tags that have an empty string in the name column do not display as expected in the component_arcgis_online_view database view. We should also make the name column nullable since we have several tags without names that use EMPTY string.

We should fix so that:

  • the name column is nullable in moped_component_tags table since we have several tags with empty strings in this column
  • the component_arcgis_online_view DB view should handle the null names and show the type only in its calculated value for its component_tags column
    • currently, the component tag name does not display at all if the name column is made nullable and EMPTY is replaced with NULL

Query to see the current formula for component tags in the AGOL view

SELECT
	((moped_component_tags.type || ' - '::text) || moped_component_tags.name) AS component_tags
FROM
	moped_component_tags;

Query for more production examples

SELECT
	project_id,
	component_id,
	component_tags
FROM
	component_arcgis_online_view
WHERE
	component_tags LIKE '%- ,%'
LIMIT
	300;

TablePlus example of current values

Image

Expected

Image

Metadata

Metadata

Assignees

Labels

Product: MopedA comprehensive mobility project tracking platform for Austin, TexasTeam: DevSoftware engineering, data integrations, and tech infrastructureType: Bug ReportSomething is not rightWorkgroup: TPWTransportation & Public Works Department

Type

No type
No fields configured for issues without a type.

Projects

Status

Closed

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions