title: store a simple string as text file in azure synapse (to data lake gen2)
body: <p>I am trying to do store a simple string as a text file in datalakeGen2 with python code written in synapse notebook. But it doesn't seems to be straight forward.</p>
  <p>I tried to convert the text into rdd and then store:</p>
  <pre><code>from pyspark import SparkConf
  from pyspark import SparkContext
  sc = SparkContext.getOrCreate(SparkConf().setMaster(&quot;local[*]&quot;))
  str = &quot;test string&quot;
  
  text_path = adls_path + 'test.xml'
  
  rdd_text = sc.parallelize(list(str)).collect()
  # type(rdd_text)
  
  rdd_text.saveAsTextFile(text_path)
  </code></pre>
  <p>but it gives out error as:</p>
  <pre><code>AttributeError: 'list' object has no attribute 'saveAsTextFile'
  Traceback (most recent call last):
  
  AttributeError: 'list' object has no attribute 'saveAsTextFile'
  </code></pre>