<?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 Why does the display name of widgets not match the specified name in SQL? in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25278#M17559</link>
    <description>&lt;P&gt;However, I have no problem accessing the widget with the specified name. &lt;span class="lia-inline-image-display-wrapper" image-alt="Screen Shot 2021-03-18 at 2.07.34 PM"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/2492iA35C881668A16DC7/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screen Shot 2021-03-18 at 2.07.34 PM" alt="Screen Shot 2021-03-18 at 2.07.34 PM" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 10 Jun 2021 18:01:44 GMT</pubDate>
    <dc:creator>User16844444140</dc:creator>
    <dc:date>2021-06-10T18:01:44Z</dc:date>
    <item>
      <title>Why does the display name of widgets not match the specified name in SQL?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25278#M17559</link>
      <description>&lt;P&gt;However, I have no problem accessing the widget with the specified name. &lt;span class="lia-inline-image-display-wrapper" image-alt="Screen Shot 2021-03-18 at 2.07.34 PM"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/2492iA35C881668A16DC7/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screen Shot 2021-03-18 at 2.07.34 PM" alt="Screen Shot 2021-03-18 at 2.07.34 PM" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Jun 2021 18:01:44 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25278#M17559</guid>
      <dc:creator>User16844444140</dc:creator>
      <dc:date>2021-06-10T18:01:44Z</dc:date>
    </item>
    <item>
      <title>Re: Why does the display name of widgets not match the specified name in SQL?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25279#M17560</link>
      <description>&lt;P&gt;What would you like the display name (3rd positional argument of dbutils.widgets.text() and the default value (2nd positional argument) to be?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I believe you may be looking to do this:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;dbutils.widgets.text("max_end_revenue_date",str(date.collect()[0]), "Max End Revenue Date ?")&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 18 Jun 2021 22:06:27 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25279#M17560</guid>
      <dc:creator>Mooune_DBU</dc:creator>
      <dc:date>2021-06-18T22:06:27Z</dc:date>
    </item>
    <item>
      <title>Re: Why does the display name of widgets not match the specified name in SQL?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25280#M17561</link>
      <description>&lt;P&gt;Just to add on, the bug in the original code is that a DataFrame named &lt;B&gt;date&lt;/B&gt; is being converted to a string via the call &lt;B&gt;str(date) &lt;/B&gt;which in term is used as the third parameter, the label, which in turn gives the weird label &lt;B&gt;DataFrame[max_end_revenue&lt;/B&gt; which is the left-most part of that to-string conversion of the DataFrame object.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can see the documentation for these methods, and the parameter lists @Amine El Helou​&amp;nbsp;is referring to, by executing the command:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;dbutils.widgets.help()&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jul 2021 21:19:08 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25280#M17561</guid>
      <dc:creator>User16857281974</dc:creator>
      <dc:date>2021-07-30T21:19:08Z</dc:date>
    </item>
    <item>
      <title>Re: Why does the display name of widgets not match the specified name in SQL?</title>
      <link>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25281#M17562</link>
      <description>&lt;P&gt;Yep, I figured out the issue now. Both of you gave the right information to solve the problem. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My first mistake was as Jacob mentioned, `date` is actually a dataframe object here. To get the string date, I had to do similar to what Amine suggested. See the screenshot here.&lt;span class="lia-inline-image-display-wrapper" image-alt="Screen Shot 2021-03-18 at 3.24.10 PM"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/2494i1A1CD6E28302205A/image-size/large?v=v2&amp;amp;px=999" role="button" title="Screen Shot 2021-03-18 at 3.24.10 PM" alt="Screen Shot 2021-03-18 at 3.24.10 PM" /&gt;&lt;/span&gt;But now I have a new problem: the date is shown as the key, rather than showing "max_end_revenue_date". This is what Amine pointed out. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;From the documentation: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;text(name: String, defaultValue: String, label: String): void -&amp;gt; Creates a text input widget with a given name and default value&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a mistake in my code. The third argument is actually the label, which is what shows up in the UI. However, `name`, which is the first positional argument, is what we would use with `dbutils.widgets.get("name")` here. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jul 2021 21:41:23 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/why-does-the-display-name-of-widgets-not-match-the-specified/m-p/25281#M17562</guid>
      <dc:creator>User16844444140</dc:creator>
      <dc:date>2021-07-30T21:41:23Z</dc:date>
    </item>
  </channel>
</rss>

