惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

W
WeLiveSecurity
The GitHub Blog
The GitHub Blog
Engineering at Meta
Engineering at Meta
Microsoft Azure Blog
Microsoft Azure Blog
The Register - Security
The Register - Security
Stack Overflow Blog
Stack Overflow Blog
博客园 - 三生石上(FineUI控件)
T
Threat Research - Cisco Blogs
S
SegmentFault 最新的问题
V2EX - 技术
V2EX - 技术
Hacker News: Ask HN
Hacker News: Ask HN
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
P
Proofpoint News Feed
J
Java Code Geeks
Microsoft Security Blog
Microsoft Security Blog
M
MIT News - Artificial intelligence
AI
AI
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
P
Proofpoint News Feed
Hacker News - Newest:
Hacker News - Newest: "LLM"
B
Blog
N
News and Events Feed by Topic
N
News | PayPal Newsroom
Google DeepMind News
Google DeepMind News
酷 壳 – CoolShell
酷 壳 – CoolShell
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
WordPress大学
WordPress大学
C
Cybersecurity and Infrastructure Security Agency CISA
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
博客园 - 【当耐特】
U
Unit 42
腾讯CDC
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
The Cloudflare Blog
H
Help Net Security
Recent Announcements
Recent Announcements
P
Privacy & Cybersecurity Law Blog
IT之家
IT之家
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Security Archives - TechRepublic
Security Archives - TechRepublic
L
LINUX DO - 热门话题
Martin Fowler
Martin Fowler
MongoDB | Blog
MongoDB | Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
H
Heimdal Security Blog
博客园 - 聂微东
S
Securelist
大猫的无限游戏
大猫的无限游戏
Cloudbric
Cloudbric
Cisco Talos Blog
Cisco Talos Blog

博客园 - 星星博客园

关于win10打开Word文件提示“转换文件”,选择文件类型的问题解决方式 关于安装R语言的Rattle报错问题的解决方式 office安装错误,报1603 apple mobile device recovery mode 问题解决 关于informix中判断字母是否为汉字的一点技巧 使用Hibernet开发informix数据库程序小结 etc的默认级别 MySQL关于TYPE和ENGIN的一点问题 转两篇关于JVM参数调优 SQL与NoSQL的一些内容汇总 informix 临时空间 导出Excel(脱离Office环境) 研究Mybatis的Jpetshop-系统搭建(一) 创建一个Jetty的Server 先写一点informix的 文件 "C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\mastlog.ldf " 已压缩,但未驻留在只读数据库或文件组中。必须将此文件解压缩。【转】 - 星星博客园 Weblogic常用监控指标(转) BEA WebLogic平台下J2EE调优攻略【转】 关于Session问题
Informix 生成随机数
星星博客园 · 2011-05-12 · via 博客园 - 星星博客园

生成随机数有两种方式:

第一种,使用存储过程 :

CREATE PROCEDURE sp_setseed(n INTEGER)
         DEFINE GLOBAL seed 
DECIMAL(10DEFAULT 1;
         LET seed 
= n;
 
END PROCEDURE;CREATE PROCEDURE sp_random(n integer) RETURNING INTEGER;
         DEFINE GLOBAL seed 
DECIMAL(10DEFAULT 1;
         DEFINE d 
DECIMAL(20,0);
         LET d 
= (seed * 1103515245+ 12345;
       
         LET seed 
= d - 4294967296 * TRUNC(d / 4294967296);
         
RETURN MOD(TRUNC(seed / 65536), n); 
 
END PROCEDURE;

第二种,使用系统的随机取值函数

x=$RANDOM