My table1 consist of below values
ResID status(bit data type)
Rule Rvalues(bit value stored as a string) status(bit)
1 101 0
2 110 1
3 001 0
In need to create an array of bits from the first table in a particular sequence order(asc order of ResID) i,e 101. This value i need to compare with each value in Table2 by performing the bitwise OR operation and the get the status from the table2. In our case final value i will get is status=0.
the values in table1 may increase to 100 as well.
This is summary of things that needs to be done:
1) Creating an array of bits.
2) Retrieving the values from table2 one by one in a butarray format.
3) Performing the bitwise OR operation.
4) fetch the exact status value from table2
Further, also let me know in which scenario the CLR based stored proceduers, triggers etc implemention are used.