Reputation: 3681
I have below XML
. I need to check if any of column in this row has a value or not.
<row>
<Row></Row>
<TaskName></TaskName>
<TaskType>someFooValue</TaskType>
<PlanDate></PlanDate>
<ForecastDate></ForecastDate>
<Status></Status>
<AssignedTo></AssignedTo>
<Predecessors></Predecessors>
<SortOrder></SortOrder>
<Duration></Duration>
<PerComplete></PerComplete>
<PlannedEndDate></PlannedEndDate>
<ForecastEndDate></ForecastEndDate>
</row>
Upvotes: 1
Views: 170
Reputation: 117380
select @data.exist('row/*[text()]')
Will return 1
if there're some non-empty value.
Upvotes: 2