<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Newbie Questions</title><link>https://www.infopathdev.com:443/forums/39.aspx</link><description>New to InfoPath? Search to see if your question has already been answered. If it has not, then ask it here or the appropriate topic forum.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Difference of nz(@ID) and max(@ID)</title><link>https://www.infopathdev.com:443/forums/thread/58243.aspx</link><pubDate>Mon, 23 Aug 2010 17:09:45 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:58243</guid><dc:creator>Jimmy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/58243.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=58243</wfw:commentRss><description>&lt;p&gt;If you&amp;#39;re using rules to assign the ID value, you can use separate rules with different conditions.&amp;nbsp; That&amp;#39;s just as good as an if/then statement.&lt;/p&gt;</description></item><item><title>Re: Difference of nz(@ID) and max(@ID)</title><link>https://www.infopathdev.com:443/forums/thread/58236.aspx</link><pubDate>Mon, 23 Aug 2010 15:17:13 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:58236</guid><dc:creator>mpeters</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/58236.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=58236</wfw:commentRss><description>&lt;p&gt;Jimmy,&lt;/p&gt;
&lt;p&gt;I have a retrieval data connection for&amp;nbsp;each forms library in SharePoint.&amp;nbsp; The secondary data source has a repeating group with just the ID field.&amp;nbsp; So everytime I submit a form to this library a new ID in a new&amp;nbsp;row is created???&amp;nbsp; If that is the case, then I guess it would be retrieving multiple rows.&amp;nbsp; I thought that there was just the one field called ID and I was always getting that one.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;So, it looks like I absolutely would need to use MAX (@ID) then.&amp;nbsp; Too bad that MAX couldn&amp;#39;t also do the check, so that you wouldn&amp;#39;t get the dreaded NaN error when there are no forms in the library.&amp;nbsp; I was&amp;nbsp;told that I can&amp;#39;t use code to perform the checks for NaN, so I&amp;#39;m sort of stuck, unless I put a form or folder in every library.&amp;nbsp; I have quite a few libraries, so I am already using the condition statement in the submit rules to determine which set of actions that I want to use for the submit.&amp;nbsp; Too bad there aren&amp;#39;t some standard &amp;#39;if&amp;nbsp;/ then&amp;#39; statements in the actions available.&amp;nbsp; Any thoughts?&lt;/p&gt;</description></item><item><title>Re: Difference of nz(@ID) and max(@ID)</title><link>https://www.infopathdev.com:443/forums/thread/58209.aspx</link><pubDate>Fri, 20 Aug 2010 17:05:55 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:58209</guid><dc:creator>Jimmy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/58209.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=58209</wfw:commentRss><description>&lt;p&gt;If your query returns multiple rows, then max(@ID) will select the highest ID value.&amp;nbsp; nz(@ID) would return the value of ID in the first row of the query results.&lt;/p&gt;
&lt;p&gt;Does your SharePoint list query retrieve several rows of results, or just one?&lt;/p&gt;</description></item><item><title>Re: Difference of nz(@ID) and max(@ID)</title><link>https://www.infopathdev.com:443/forums/thread/58198.aspx</link><pubDate>Fri, 20 Aug 2010 12:52:23 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:58198</guid><dc:creator>mpeters</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/58198.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=58198</wfw:commentRss><description>&lt;p&gt;Thanks for the reply Hilary!&amp;nbsp;&lt;/p&gt;
&lt;p&gt;When you are using these functions specifically with the ID field for auto-numbering the forms, shouldn&amp;#39;t the result using NZ&amp;nbsp;or MAX be the same?&amp;nbsp; When I setup my data connections for my&amp;nbsp;form libraries&amp;nbsp;and I select ID from the SharePoint list, I&amp;#39;m thinking it is just one field, so NZ or MAX should have the same result right?&amp;nbsp; My tests&amp;nbsp;do not&amp;nbsp;support that conclusion, though.&lt;/p&gt;</description></item><item><title>Re: Difference of nz(@ID) and max(@ID)</title><link>https://www.infopathdev.com:443/forums/thread/58175.aspx</link><pubDate>Fri, 20 Aug 2010 00:40:14 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:58175</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/58175.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=58175</wfw:commentRss><description>&lt;p&gt;Hi:&lt;/p&gt;
&lt;p&gt;From &lt;a href="http://office.microsoft.com/en-us/infopath-help/functions-in-infopath-HP001155281.aspx"&gt;Office Online&lt;/a&gt;, nz &amp;quot;Returns the value of the specified field. If the field is blank, it returns zero (0)&amp;quot;, whereas max &amp;quot;Returns the largest number in the argument&amp;quot;. &lt;/p&gt;
&lt;p&gt;Practically, that means that nz is only looking at a single field -- so if your field is, for example, in a repeating data group, it will only evaluate the first instance of the field in that group. Max, on the other hand, evaluates all instances of a field. So, if your field is in a repeating group, max looks at all instances of the field and returns the max. Does that make sense?&lt;/p&gt;</description></item><item><title>Difference of nz(@ID) and max(@ID)</title><link>https://www.infopathdev.com:443/forums/thread/58170.aspx</link><pubDate>Thu, 19 Aug 2010 20:11:26 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:58170</guid><dc:creator>mpeters</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/58170.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=58170</wfw:commentRss><description>&lt;p&gt;What exactly is the difference in what is returned?&amp;nbsp; I set up a field that displayed both.&amp;nbsp; After initially getting zero for NZ when the folder was emply, I didn&amp;#39;t see a difference for a while.&amp;nbsp; Then, after saving a form and opening it up and submitting it, there was a difference.&amp;nbsp; After that the nz result didn&amp;#39;t change, even when I set autonumber = nz(@ID), then display autonumber + 1.&lt;/p&gt;</description></item></channel></rss>