title: How to read file path values as columns in Spark?
body: <p>I'm working in Azure Synapse Notebooks and reading reading file(s) into a Dataframe from a well-formed folder path like so:</p>
  <p><a href="https://i.stack.imgur.com/oFTWN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/oFTWN.png" alt="enter image description here" /></a></p>
  <p>Given there are many folders references by that wildcard, how do I capture the &quot;State&quot; value as a column in the resulting Dataframe?</p>