<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: DLT: Only STREAMING tables can have multiple queries. in Get Started Discussions</title>
    <link>https://community.databricks.com/t5/get-started-discussions/dlt-only-streaming-tables-can-have-multiple-queries/m-p/59717#M6473</link>
    <description>&lt;P&gt;I should also add that when I drop the `backfill` function, validation happens successfully and we get the following pipeline DAG:&lt;/P&gt;</description>
    <pubDate>Thu, 08 Feb 2024 16:53:04 GMT</pubDate>
    <dc:creator>coltonflowers</dc:creator>
    <dc:date>2024-02-08T16:53:04Z</dc:date>
    <item>
      <title>DLT: Only STREAMING tables can have multiple queries.</title>
      <link>https://community.databricks.com/t5/get-started-discussions/dlt-only-streaming-tables-can-have-multiple-queries/m-p/59714#M6472</link>
      <description>&lt;P&gt;I am trying to to do a one-time back-fill on a DLT table following the example &lt;A href="https://docs.databricks.com/en/delta-live-tables/python-ref.html#example-run-a-one-time-data-backfill" target="_self"&gt;here&lt;/A&gt;:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;dlt.table()
def test():
    # providing a starting version
    return (spark.readStream.format("delta") 
        .option("readChangeFeed", "true") 
        .option("startingTimestamp", "2024-01-7 05:00:00") 
        .table("LIVE.concepts_to_flag")
        .select("group_id","cui","cel_label",F.array([F.lit("fake")]),F.lit(True))
    )
@dlt.append_flow(target = "test")
def backfill():
  return spark.readStream.option("endingTimestamp", "2024-01-7 05:00:00").table("hive_metastore.gold.flagged_entities")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;However, after validating this pipeline, get the following error:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;org.apache.spark.sql.AnalysisException: 'test' contains multiple queries 'test,backfill'. Only STREAMING tables can have multiple queries.&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 08 Feb 2024 16:13:46 GMT</pubDate>
      <guid>https://community.databricks.com/t5/get-started-discussions/dlt-only-streaming-tables-can-have-multiple-queries/m-p/59714#M6472</guid>
      <dc:creator>coltonflowers</dc:creator>
      <dc:date>2024-02-08T16:13:46Z</dc:date>
    </item>
    <item>
      <title>Re: DLT: Only STREAMING tables can have multiple queries.</title>
      <link>https://community.databricks.com/t5/get-started-discussions/dlt-only-streaming-tables-can-have-multiple-queries/m-p/59717#M6473</link>
      <description>&lt;P&gt;I should also add that when I drop the `backfill` function, validation happens successfully and we get the following pipeline DAG:&lt;/P&gt;</description>
      <pubDate>Thu, 08 Feb 2024 16:53:04 GMT</pubDate>
      <guid>https://community.databricks.com/t5/get-started-discussions/dlt-only-streaming-tables-can-have-multiple-queries/m-p/59717#M6473</guid>
      <dc:creator>coltonflowers</dc:creator>
      <dc:date>2024-02-08T16:53:04Z</dc:date>
    </item>
  </channel>
</rss>

