<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://bloggingabout.net/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>Search results matching tags 'SQL', 'bitwise operators', 'MSSQL', 'tsql', and 'numeric'</title><link>http://bloggingabout.net/search/SearchResults.aspx?a=1&amp;o=DateDescending&amp;tag=SQL,bitwise+operators,MSSQL,tsql,numeric&amp;orTags=0</link><description>Search results matching tags 'SQL', 'bitwise operators', 'MSSQL', 'tsql', and 'numeric'</description><dc:language>en-US</dc:language><generator>CommunityServer 2008.5 SP2 (Build: 40407.4157)</generator><item><title>Mssql: Cannot use bitwise operators on varbinary or numeric</title><link>http://bloggingabout.net/blogs/ramon/archive/2008/02/25/mssql-cannot-use-bitwise-operators-op-varbinary-or-numeric.aspx</link><pubDate>Mon, 25 Feb 2008 08:23:00 GMT</pubDate><guid isPermaLink="false">813b6dfd-644e-4573-a816-eebab56ba0d0:457941</guid><dc:creator>Ramon Smits</dc:creator><description>&lt;p&gt;I want to perform bitwise operations on a varbinary colum. As it contains binary data I though that it would work but it didn&amp;#39;t&lt;br /&gt; &lt;/p&gt;&lt;p&gt;&lt;b&gt;This example works:&lt;/b&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;declare @a int&lt;br /&gt;declare @b int&lt;br /&gt;&lt;br /&gt;set @a = 1&lt;br /&gt;set @b = 2&lt;br /&gt;&lt;br /&gt;select @a | @b&lt;/p&gt;&lt;p&gt;&lt;b&gt;But this wont:&lt;/b&gt;&lt;/p&gt;&lt;p&gt;declare @a varbinary(100)&lt;br /&gt;declare @b varbinary(100)&lt;br /&gt;
&lt;br /&gt;
set @a = 1&lt;br /&gt;
set @b = 2&lt;br /&gt;
&lt;br /&gt;
select @a | @b&lt;/p&gt;&lt;br /&gt;The same problem with numeric data type. So that currently leaves me without a mssql solution. I guess I have to fallback to code to perform the conversion that I need.&lt;br /&gt;</description></item></channel></rss>