PostgreSQL中的二进制转换程序(补充)
来源:百度文库 编辑:神马文学网 时间:2024/04/29 10:04:14
IP转换为整数: select cast((int1::bit(64)<<24)|(int2::bit(64)<<16)|(int3::bit(64)<<8)|(int4::bit(64)) as bigint) into ret_ip; 二进制字符串转换为IP地址:
tmp_bit := str_bit::bit(64);
len := length(tmp_bit);
--先頭の32桁は ’0’です。
for i in 33..len by 8 loop
tmp_int := substring(tmp_bit, i, 8) :: bigint;
if i-32 = 1 then
ip := ip || tmp_int ;
else
ip := ip || ‘.‘ || tmp_int ;
end if;
end loop;
PostgreSQL中的二进制转换程序(补充)
PostgreSQL中的二进制转换程序(补充)
十进制转换为二进制的方法(同理八进制、十六进制转换为二进制的方法)
专题研究:企业改制过程中的税收问题(补充修订版)
二进制数
《人鬼情未了》中的时空转换
谈谈Windows程序中的字符编码(1)
谈谈Windows程序中的字符编码(2)
谈谈Windows程序中的字符编码(3)
谈谈Windows程序中的字符编码(2)
谈谈Windows程序中的字符编码(1)
3步把您的java程序转换为webservice
Ubuntu 9.10下搭建基于PostgreSQL的Redmine(下) - CodeCake
Ubuntu 9.10下搭建基于PostgreSQL的Redmine(上) - CodeCake
二进制和二进制补码的四则运算
血管紧张素转换酶抑制剂(ACEI)在治疗高血压中的应用
struts2学习笔记(2)struts2中的类型转换_0-1World
路由器在网络地址转换中的应用简介
Matlab中的几个类型转换函数
php读取二进制流(C语言结构体struct数据文件)
二进制全加器,元件声明与元件例化(COMPONENT,PORT MAP)
二、二进制的四则运算
第五讲 二进制初步
以二进制读取文本文件