<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Mersoft Corporation Blog &#187; powerbuilder</title>
	<atom:link href="http://blog.mersoft.com/tag/powerbuilder/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.mersoft.com</link>
	<description>Achieve, Compete, and Evolve</description>
	<lastBuildDate>Tue, 25 May 2010 15:37:24 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>PowerBuilder 11 &#8220;Invalid character value for cast specification&#8221;</title>
		<link>http://blog.mersoft.com/2009/12/03/powerbuilder-11-invalid-character-value-for-cast-specification/</link>
		<comments>http://blog.mersoft.com/2009/12/03/powerbuilder-11-invalid-character-value-for-cast-specification/#comments</comments>
		<pubDate>Thu, 03 Dec 2009 22:26:23 +0000</pubDate>
		<dc:creator>Mandi Zinn</dc:creator>
				<category><![CDATA[Software Development]]></category>
		<category><![CDATA[invalid character]]></category>
		<category><![CDATA[Microsoft SQL Server 2000]]></category>
		<category><![CDATA[odbc]]></category>
		<category><![CDATA[powerbuilder]]></category>
		<category><![CDATA[SNC]]></category>

		<guid isPermaLink="false">http://blog.mersoft.com/?p=335</guid>
		<description><![CDATA[I was given the task of migrating a set of powerbuilder applications from version 8 to 11.5.
The PowerBuilder applications required a database connection. I went through their connection utility and the only connection type that I could get to work with my Microsoft SQL Server 2000 was ODBC. I configured it and PowerBuilder told me [...]]]></description>
			<content:encoded><![CDATA[<p>I was given the task of migrating a set of powerbuilder applications from version 8 to 11.5.</p>
<p>The PowerBuilder applications required a database connection. I went through their connection utility and the only connection type that I could get to work with my Microsoft SQL Server 2000 was ODBC. I configured it and PowerBuilder told me that it was working properly. I configured all of the applications to use the ODBC.</p>
<p>All of the applications worked properly, except one: the only application that uses stored procedures. The stored procedures that were failing had input and output parameters. They kept giving me the error message of</p>
<pre>
     [Microsoft][ODBC SQL Server Driver] Invalid character value for cast specification
</pre>
<p>I figured the problem was just a configuration issue. After extensive research, I found one forum that had a solution: adding </p>
<pre>
      StripParmNames='Yes',CallEscape='No'
</pre>
<p>to the end of the DBParm. I tried this. It fixed the &#8220;Invalid character&#8221; problem, but then I started getting the following error message:</p>
<pre>
     [Microsoft][ODBC SQL Server Driver] Incorrect syntax near 'OUTPUT'
</pre>
<p>Since everything seems to change when you tweak parameters, I tried every combination of parameters that I could see as possibly making a difference (both on the ODBC connection configuration and the DBParm settings).</p>
<p>Finally, I looked back at the original configuration and noticed that the DBMS was &#8220;MSS (Msoft) SQL Server 2000&#8243;. I started researching PowerBuilder database connection options and found this blog:</p>
<p><a href="http://sureshmoorthy.blogspot.com/2008/05/migrating-to-powerbuilder-11.html?showComment=1239682860000#c3657249529659890174">http://sureshmoorthy.blogspot.com/2008/05/migrating-to-powerbuilder-11.html?showComment=1239682860000#c3657249529659890174</a></p>
<p>Mainly, that PowerBuilder&#8217;s native driver (MSS) had been removed from PowerBuilder version 10 and that PowerBuilder 11 replaced it with SNC to support SQL Server 2000 &amp; 2005. Finally, I had found my solution. I switched my configuration to use the SNC driver and it solved all the problems I was having. Here&#8217;s the new configuration:</p>
<pre>
  DBMS=SNC
  Database=&lt;database name&gt;
  ServerName=&lt;server IP address&gt;
  LogId=&lt;db user name&gt;
  LogPassword=&lt;db password&gt;
  Lock=RU
  DbParm=staticbind=0,Async=1,AppName='&lt;app name&gt;'
</pre>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fblog.mersoft.com%2F2009%2F12%2F03%2Fpowerbuilder-11-invalid-character-value-for-cast-specification%2F&amp;linkname=PowerBuilder%2011%20%26%238220%3BInvalid%20character%20value%20for%20cast%20specification%26%238221%3B"><img src="http://blog.mersoft.com/wp-content/plugins/add-to-any/share_save_171_16.gif" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://blog.mersoft.com/2009/12/03/powerbuilder-11-invalid-character-value-for-cast-specification/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
