C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !






Bitwise logical OR


Posted Date: 28 May 2008    Resource Type: Articles    Category: General
Author: Kapil DhawanMember Level: Gold    
Rating: Points: 5



Introduction



Here is the example of using Bitwise Logical OR
Performs a bitwise logical OR operation between two integer values.

>Syntax
Syntax for using this is:

1st Statement | 2nd Statement

Example


for example use this query in Sql server
select 50 | 60
you will get the result as 62

These Statements will be of Integer. Statements will be used as binary number for the bitwise operation.


The binary representation of 50 is 0011 0010. The binary representation of 60 is 0011 1100. Performing the bitwise OR operation on these two values produces the binary result 0011 1110, which is decimal 62.

0011 0010
0011 1100
_______________________
0011 1110 this is equal to 62

Note: while using "|"
0+0=0,
0+1=1,
1+1=1




Responses

Author: Mahesh Raj    07 Jun 2008Member Level: Gold   Points : 1
This is very good information,Continue posting such useful articles.


Author: hairat    08 Jun 2008Member Level: Bronze   Points : 0
good article


Author: John Fernandez    08 Jun 2008Member Level: Gold   Points : 1
Very well written Article.Thanks for sharing this information.


Author: John Fernandez    08 Jun 2008Member Level: Gold   Points : 1
Very well written Article.Thanks for sharing this information.


Feedbacks      
Popular Tags   What are tags ?   Search Tags  
(No tags found.)

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: Decimal and Hexadecimal Representation
Previous Resource: Convert Currency to English Words
Return to Discussion Resource Index
Post New Resource
Category: General


Post resources and earn money!
 
Related Resources



dotNet Slackers   BizTalk Adaptors    Web Design


Contact Us    Privacy Policy    Terms Of Use