Re: Converting decimal to binary

2006-01-18 Thread Ed Reed
Actually please ignore my previous question. I just had a brain cramp. Thanks >>> "Ed Reed" <[EMAIL PROTECTED]> 1/18/06 11:34:11 AM >>> Can you (or anyone else) explain to me how, or point me somewhere that I can learn how this works? I'd really like to know more about how bitwise arithmetic

Re: Converting decimal to binary

2006-01-18 Thread Ed Reed
Can you (or anyone else) explain to me how, or point me somewhere that I can learn how this works? I'd really like to know more about how bitwise arithmetic works. Thanks >>> Francesco Riosa <[EMAIL PROTECTED]> 1/10/06 4:58:47 PM >>> Francesco Riosa wrote: > And another one is (in inverse orde

Re: [SPAM] - Re: Converting decimal to binary - Bayesian Filter detected spam

2006-01-10 Thread Francesco Riosa
Francesco Riosa wrote: > And another one is (in inverse order for laziness): > > select > (8 & 1) AS `0` > , (8 & 2 > 1) AS `1` > , (8 & 4 > 1) AS `2` > , (8 & 8 > 1) AS `3` > , (8 & 16 > 1) AS `4` > , (8 & 32 > 1) AS `5` > , (8 & 64 > 1) AS `6` > , (8 & 128 > 1) AS `7` > ; > but this one look

Re: [SPAM] - Re: Converting decimal to binary - Bayesian Filter detected spam

2006-01-10 Thread Francesco Riosa
> > > > >>>> "Gordon Bruce" < [EMAIL PROTECTED] > 1/10/06 1:44 PM >>> >>>> > Actually CONV converts from any base to any base so if it is base 10 > then just replace the 16's with 10's. > > Too much ti

RE: [SPAM] - Re: Converting decimal to binary - Bayesian Filter detected spam

2006-01-10 Thread Ed Reed
n just replace the 16's with 10's. Too much time looking at dump's. -Original Message- From: Bill Dodson [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 10, 2006 3:09 PM To: Gordon Bruce Cc: Ed Reed; mysql@lists.mysql.com Subject: [SPAM] - Re: Converting decimal to

RE: [SPAM] - Re: Converting decimal to binary - Bayesian Filter detected spam

2006-01-10 Thread Ed Reed
Reed; mysql@lists.mysql.com Subject: [SPAM] - Re: Converting decimal to binary - Bayesian Filter detected spam If you really do mean decimal (base 10) you could use Gordon's solution like this: SELECT MID(CONV(HEX(245),16,2),1,1) AS `7`, MID(CONV(HEX(245),16,2),2,1) AS `6`, MID(CONV(HEX(2

RE: [SPAM] - Re: Converting decimal to binary - Bayesian Filter detected spam

2006-01-10 Thread Gordon Bruce
Ed Reed; mysql@lists.mysql.com Subject: [SPAM] - Re: Converting decimal to binary - Bayesian Filter detected spam If you really do mean decimal (base 10) you could use Gordon's solution like this: SELECT MID(CONV(HEX(245),16,2),1,1) AS `7`, MID(CONV(HEX(245),16,2),2,1) AS `6`, MID(CONV(HEX(245),16

Re: Converting decimal to binary

2006-01-10 Thread Bill Dodson
+---+---+---+---+ 1 row in set (0.00 sec) -Original Message- From: Ed Reed [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 10, 2006 12:16 PM To: mysql@lists.mysql.com Subject: Converting decimal to binary Can anyone tell me if it's possible, in 4.1.11, to convert a decimal number to b

RE: Converting decimal to binary

2006-01-10 Thread Gordon Bruce
1 row in set (0.00 sec) -Original Message- From: Ed Reed [mailto:[EMAIL PROTECTED] Sent: Tuesday, January 10, 2006 12:16 PM To: mysql@lists.mysql.com Subject: Converting decimal to binary Can anyone tell me if it's possible, in 4.1.11, to convert a decimal number to binary and

Converting decimal to binary

2006-01-10 Thread Ed Reed
Can anyone tell me if it's possible, in 4.1.11, to convert a decimal number to binary and have the result be returned as a separate field for each bit? For example, what I'd like to do is, Select ConvertToBin(245); And have a result that looked like this +---+---+---+---+---+---+---+---+ | 7 |