<?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: Sometimes &amp;quot;Invalid parameter value passed to function&amp;quot; when using ChangePrivilege in Data Management Questions</title>
    <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537435#M30482</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;You write that ArcSDE on the server is also running 9.2 but is there a chance it has a newer or older ArcGIS Desktop than your workstation?&amp;nbsp; Didn't the parameter list of the ChangePrivileges command change between versions?&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;It is the same ArcGIS version (9.2) on both the workstation and the server, and I think also the same SP; but I will check this. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Ralph&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 10 Aug 2010 17:33:03 GMT</pubDate>
    <dc:creator>RPW</dc:creator>
    <dc:date>2010-08-10T17:33:03Z</dc:date>
    <item>
      <title>Sometimes "Invalid parameter value passed to function" when using ChangePrivileges</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537432#M30479</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am automatically setting permissions on Feature Classes in ArcSDE using Python. &lt;/SPAN&gt;&lt;STRONG&gt;The problem is that this only works if I run the script on the workstation; if I run it directly on the server where ArcSDE is installed, I get the following error message:&lt;BR /&gt;&lt;BR /&gt;Invalid parameter value passed to function&lt;BR /&gt;Failed to execute (ChangePrivileges).&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The command looks the same using both ways (print gp.GetMessages()):&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Executing: ChangePrivileges &amp;lt;SDE_CONN_FILE&amp;gt;/&amp;lt;ADMIN_USER&amp;gt;.&amp;lt;FC&amp;gt; &amp;lt;USER&amp;gt; GRANT AS_IS &amp;lt;SDE_CONN_FILE&amp;gt;/&amp;lt;ADMIN_USER&amp;gt;.&amp;lt;FC&amp;gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The strange thing is that the FC is appended again in the end, although the syntax looks like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;ChangePrivileges_management (in_dataset, user, view, edit) &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;But I don't think this is the reason, since it works on the workstation.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is the code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;# Process only FC where admin_user has access -&amp;gt; wildcard
&amp;nbsp; wildcard = "%s.*" % admin_user
&amp;nbsp; fcs = gp.ListFeatureClasses(wildcard)
&amp;nbsp; fcs.reset()
&amp;nbsp; fc = fcs.next()
&amp;nbsp; 
&amp;nbsp; while fc:
&amp;nbsp;&amp;nbsp; fc = conn_sde + "/" + fc
&amp;nbsp;&amp;nbsp; print "Setting read permission on FC %s" % fc
&amp;nbsp;&amp;nbsp; try:
&amp;nbsp;&amp;nbsp;&amp;nbsp; # Process: Change Privileges...
&amp;nbsp;&amp;nbsp;&amp;nbsp; gp.ChangePrivileges_management(fc, read_user, "GRANT", "AS_IS")
&amp;nbsp;&amp;nbsp;&amp;nbsp; print gp.GetMessages()
&amp;nbsp;&amp;nbsp; except:
&amp;nbsp;&amp;nbsp;&amp;nbsp; # If an error occurred while running a tool print the messages
&amp;nbsp;&amp;nbsp;&amp;nbsp; print gp.GetMessages()
&amp;nbsp;&amp;nbsp;&amp;nbsp; return 1
&amp;nbsp;&amp;nbsp; fc = fcs.next()&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;ArcGIS version: 9.2, SP6&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;ArcSDE version: ArcSDE for Oracle9i 9.2 Service Pack 3 &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Does anyone know why the same command would run on a workstation but not on the server?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks a lot,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Ralph&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 23:20:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537432#M30479</guid>
      <dc:creator>RPW</dc:creator>
      <dc:date>2021-12-11T23:20:10Z</dc:date>
    </item>
    <item>
      <title>Re: Sometimes "Invalid parameter value passed to function" when using ChangePrivilege</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537433#M30480</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;You write that ArcSDE on the server is also running 9.2 but is there a chance it has a newer or older ArcGIS Desktop than your workstation?&amp;nbsp; Didn't the parameter list of the ChangePrivileges command change between versions?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Aug 2010 15:44:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537433#M30480</guid>
      <dc:creator>RandyKreuziger</dc:creator>
      <dc:date>2010-08-10T15:44:14Z</dc:date>
    </item>
    <item>
      <title>Re: Sometimes "Invalid parameter value passed to function" when using ChangePrivilege</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537434#M30481</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;If you enable tracing (&lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002q000000mz000000.htm"&gt;with SDETRACELOC/SDETRACEMODE variables&lt;/A&gt;&lt;SPAN&gt;), you'll know what's wrong for sure, &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;but 92sp3 != 92sp6, so your PATH order in resolving SDE.DLL could be the deciding factor.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- V&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Aug 2010 16:39:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537434#M30481</guid>
      <dc:creator>VinceAngelo</dc:creator>
      <dc:date>2010-08-10T16:39:22Z</dc:date>
    </item>
    <item>
      <title>Re: Sometimes "Invalid parameter value passed to function" when using ChangePrivilege</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537435#M30482</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;You write that ArcSDE on the server is also running 9.2 but is there a chance it has a newer or older ArcGIS Desktop than your workstation?&amp;nbsp; Didn't the parameter list of the ChangePrivileges command change between versions?&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;It is the same ArcGIS version (9.2) on both the workstation and the server, and I think also the same SP; but I will check this. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Ralph&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Aug 2010 17:33:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537435#M30482</guid>
      <dc:creator>RPW</dc:creator>
      <dc:date>2010-08-10T17:33:03Z</dc:date>
    </item>
    <item>
      <title>Re: Sometimes "Invalid parameter value passed to function" when using ChangePrivilege</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537436#M30483</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;If you enable tracing (&lt;A href="http://help.arcgis.com/en/arcgisdesktop/10.0/help/index.html#//002q000000mz000000.htm"&gt;with SDETRACELOC/SDETRACEMODE variables&lt;/A&gt;), you'll know what's wrong for sure, &lt;BR /&gt;but 92sp3 != 92sp6, so your PATH order in resolving SDE.DLL could be the deciding factor.&lt;BR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I will try to enable the tracing. I don't understand the thing with the PATH order and the SDE.DLL; are these critical for the ChangePrivileges cmd or for the tracing?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Ralph&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Aug 2010 17:39:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537436#M30483</guid>
      <dc:creator>RPW</dc:creator>
      <dc:date>2010-08-10T17:39:01Z</dc:date>
    </item>
    <item>
      <title>Re: Sometimes "Invalid parameter value passed to function" when using ChangePrivilege</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537437#M30484</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;If you have ArcSDE 9.2sp3 and ArcGIS 9.2sp6 on the same host, they will both have&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;a DLL named "SDE.DLL", but one will be SP3 and one will be SP6.&amp;nbsp; The LoadLibraryEx()&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;function is used to load dynamic libraries, and it searches directories in the order&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;specified by the PATH variable.&amp;nbsp; If your SP3 bin directory is before the SP6 directory,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;then the 92sp6 ArcGIS will use the outdated DLL, making it unreliable.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;There are a multitude of reasons to install ArcSDE 9.2 SP6 and the post-SP6 patches;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;eliminating search order conflicts as a possible problem is one of the less pressing ones,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;but if it works, then the other issues won't give you trouble either.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;- V&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Aug 2010 18:41:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537437#M30484</guid>
      <dc:creator>VinceAngelo</dc:creator>
      <dc:date>2010-08-10T18:41:02Z</dc:date>
    </item>
    <item>
      <title>Re: Sometimes "Invalid parameter value passed to function" when using ChangePrivilege</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537438#M30485</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;If you have ArcSDE 9.2sp3 and ArcGIS 9.2sp6 on the same host, they will both have&lt;BR /&gt;a DLL named "SDE.DLL", but one will be SP3 and one will be SP6.&amp;nbsp; The LoadLibraryEx()&lt;BR /&gt;function is used to load dynamic libraries, and it searches directories in the order&lt;BR /&gt;specified by the PATH variable.&amp;nbsp; If your SP3 bin directory is before the SP6 directory,&lt;BR /&gt;then the 92sp6 ArcGIS will use the outdated DLL, making it unreliable.&lt;BR /&gt; &lt;BR /&gt;There are a multitude of reasons to install ArcSDE 9.2 SP6 and the post-SP6 patches;&lt;BR /&gt;eliminating search order conflicts as a possible problem is one of the less pressing ones,&lt;BR /&gt;but if it works, then the other issues won't give you trouble either.&lt;BR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for the detailed explanation. I will be able to have a look at this next week. And yes, probably it would not harm to install some SPs and patches &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Cheers,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Ralph&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Aug 2010 05:23:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537438#M30485</guid>
      <dc:creator>RPW</dc:creator>
      <dc:date>2010-08-11T05:23:45Z</dc:date>
    </item>
    <item>
      <title>Re: Sometimes "Invalid parameter value passed to function" when using ChangePrivilege</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537439#M30486</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Ralph, &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;One other thing to double check is to ensure that the SDE connection file that you are using on the server is using exactly the same connection properties as the one you are using on the client machine.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Aug 2010 15:02:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537439#M30486</guid>
      <dc:creator>RussellBrennan</dc:creator>
      <dc:date>2010-08-11T15:02:08Z</dc:date>
    </item>
    <item>
      <title>Re: Sometimes "Invalid parameter value passed to function" when using ChangePrivilege</title>
      <link>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537440#M30487</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;&lt;BR /&gt;One other thing to double check is to ensure that the SDE connection file that you are using on the server is using exactly the same connection properties as the one you are using on the client machine.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Russell,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I am using exactly the same SDE connection file.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Ralph&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 12 Aug 2010 05:25:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/sometimes-quot-invalid-parameter-value-passed-to/m-p/537440#M30487</guid>
      <dc:creator>RPW</dc:creator>
      <dc:date>2010-08-12T05:25:58Z</dc:date>
    </item>
  </channel>
</rss>

