<?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: When does rand() compute/update? in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068904#M357154</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For your first question: As far as I know it will be updated each time the application is reloaded.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Second question: I usuaully use AutoNumber() to anonymize data. Something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;'Part ' &amp;amp; AutoNumber([Part No.]) as [Part No.]&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 25 Jan 2016 19:10:27 GMT</pubDate>
    <dc:creator>sunny_talwar</dc:creator>
    <dc:date>2016-01-25T19:10:27Z</dc:date>
    <item>
      <title>When does rand() compute/update?</title>
      <link>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068903#M357153</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm building a demo app that is based on one of my customers actual data.&amp;nbsp; I need to "fudge" the numbers on a couple of charts so I'm not giving out real data from this customer during presentations. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I just multiplied the expression value by rand() which worked fine.&amp;nbsp; But my question is when does that function actually get computed when viewing over the AccessPoint?&amp;nbsp; Does it happen every time the document is opened?&amp;nbsp; On reload?&amp;nbsp; Only once ever?&amp;nbsp; I can't seem to figure it out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also if anybody has ideas about a better way to do this let me know.&amp;nbsp; I don't like the built in "scramble" feature because I need to have some control over the results so the data is somewhat realistic.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2016 18:43:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068903#M357153</guid>
      <dc:creator>dcmcderm</dc:creator>
      <dc:date>2016-01-25T18:43:42Z</dc:date>
    </item>
    <item>
      <title>Re: When does rand() compute/update?</title>
      <link>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068904#M357154</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For your first question: As far as I know it will be updated each time the application is reloaded.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Second question: I usuaully use AutoNumber() to anonymize data. Something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;'Part ' &amp;amp; AutoNumber([Part No.]) as [Part No.]&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2016 19:10:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068904#M357154</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2016-01-25T19:10:27Z</dc:date>
    </item>
    <item>
      <title>Re: When does rand() compute/update?</title>
      <link>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068905#M357155</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Rand Function:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Rand() only returns a numbers between 0 and 1. You can use the result of rand to select from a list of numbers using various arithmetic and rounding operations. Some examples:&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;=ceil(rand()*1000,100)&amp;nbsp; -&amp;gt;It will Generate a number between 100 and 1000 in multiples of 100&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;=left(rand()*10,1)&amp;nbsp; -&amp;gt; Numbers 1 to 10&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;PFA,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;Hirish&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2016 19:21:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068905#M357155</guid>
      <dc:creator>HirisH_V7</dc:creator>
      <dc:date>2016-01-25T19:21:34Z</dc:date>
    </item>
    <item>
      <title>Re: When does rand() compute/update?</title>
      <link>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068906#M357156</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;if you are talking about using RAND() in the frontend, i.e. in a chart expression, I think it's somehow bound to selection states, i.e. it changes when you make different selections, but same value for same selection state.&lt;/P&gt;&lt;P&gt;Something like this, AFAIR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edit: as mentioned above, reloading data will also reset your RAND() values&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2016 19:34:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068906#M357156</guid>
      <dc:creator>swuehl</dc:creator>
      <dc:date>2016-01-25T19:34:29Z</dc:date>
    </item>
    <item>
      <title>Re: When does rand() compute/update?</title>
      <link>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068907#M357157</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This is a difficult one. fumble with actual numbers will either make them fall out of an acceptable range, or won't change them enough to actually look different.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;On the other hand, it's usually enough to obfuscate the identifying information instead of the amounts and quantities. If your demo document contains multiple customers/products/areas, just scramble or randomize the names and text strings in order to get just enough anonimity. . &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2016 20:00:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068907#M357157</guid>
      <dc:creator>Peter_Cammaert</dc:creator>
      <dc:date>2016-01-25T20:00:36Z</dc:date>
    </item>
    <item>
      <title>Re: When does rand() compute/update?</title>
      <link>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068908#M357158</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, I tested this and you are right.&amp;nbsp; I created a text object that just displayed the result of the rand() function.&amp;nbsp; It changed every time I made a selection, but then changed back to it's previous value if I returned the document to its previous state.&amp;nbsp; And a reload seems to reset the value completely as well.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2016 20:02:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068908#M357158</guid>
      <dc:creator>dcmcderm</dc:creator>
      <dc:date>2016-01-25T20:02:52Z</dc:date>
    </item>
    <item>
      <title>Re: When does rand() compute/update?</title>
      <link>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068909#M357159</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;My customers are very non-tech savvy and I've found that if I scramble the names of actual entities (mine are names of health care providers, cities, clinical terminology etc.) they can't "make the leap" to put what I'm showing them into context. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I've done is use my existing customers production data but have all charts report a value between 75% and 125% of the "actual" value.&amp;nbsp; That way all the text is intact, the values are believable in a real world scenario since they are still in the same ballpark, and the customers real/accurate performance data can't be gathered from it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 25 Jan 2016 20:07:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/When-does-rand-compute-update/m-p/1068909#M357159</guid>
      <dc:creator>dcmcderm</dc:creator>
      <dc:date>2016-01-25T20:07:57Z</dc:date>
    </item>
  </channel>
</rss>

