Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: Kind of cool feature! DBMS_RANDOM
Yeah,
on the production side I am as well. But I am building a rather large demo
enviroment with millions of rows in many different tables, and use this to
start building some cool scripts for testing.
"Do not criticize someone until you walked a
mile in their shoes, that way when you criticize them, you are a mile a way and
have their shoes."
Christopher R. Spence <FONT
face="Comic Sans MS" size=2>Oracle DBA <FONT face="Comic Sans MS" size=2>Phone: (978) 322-5744 <FONT face="Comic Sans MS" size=2>Fax: (707) 885-2275
face="Comic Sans MS" size=2>73 Princeton Street <FONT face="Comic Sans MS" size=2>North, Chelmsford 01863 <FONT face="Comic Sans MS" size=2>
<FONT
face=Tahoma size=2>-----Original Message-----From: Anjan Thakuria
[mailto:anjan.thakuria_at_eds.com] Sent: Thursday, September 06, 2001
12:36 PMTo: Multiple recipients of list ORACLE-LSubject:
Re: Kind of cool feature! DBMS_RANDOMJack, Chris,
Thanks. Don't get play with these a whole lot being on the production side.
Both of your experiences with this sounds very exciting.
Need to do some research.
Thanks again.
Anjan
"Jack C. Applewhite" wrote:
<FONT
face=Arial><FONT
size=-1>Anjan,<SPAN
class=250283722-05092001><FONT
face=Arial>Look in Oracle_Home/RDBMS/admin
for the dbmsrand.sql file. The package is better documented there, at
least for the 8.1.6 release.<SPAN
class=250283722-05092001><FONT
face=Arial>I used it last year to generate
a Session ID for a Web-accessible application to maintain state across a
User's multiple page hits.<SPAN
class=250283722-05092001><FONT
face=Arial><FONT size=-1>Jack<FONT size=-1>-------------------------------- Jack C.Applewhite Database Administrator/Developer OCP Oracle8 DBA iNetProfit,
size=-1>www.iNetProfit.com <FONT size=-1>japplewhite_at_inetprofit.com <FONT size=-1>(512)327-9068 <FONT size=-1>-----Original Message----- <FONT face=Tahoma>From: root_at_fatcity.com [<A href="mailto:root_at_fatcity.com">mailto:root_at_fatcity.com]On Behalf Of Anjan Thakuria <FONT size=-1>Sent: Wednesday, September 05, 2001 5:26 PM To: Multiple recipients of list ORACLE-L Subject: Re: Kind of cool feature! DBMS_RANDOM Hi Chris, Pl excuse me for writing directly. I looked up this package and there is no mention of the STRING option at all. Metalink search returned no hits. Could you please send me the location where you got the information from. Thanks in advance Anjan Christopher Spence wrote: In 8.1.6 Oracle added a new feature which I don't believe is very well documented, it is great. DBMS_RANDOM.STRING([OPT], [LEN]); This will create a random string with a length of up to 60 characters. Great for force populating tables. The opt is for things like L, U, M (Lower, Upper, Mixed case), there are a few different options. One thing I did to force populate a table is: DBMS_RANDOM.STRING('U', DBMS_RANDOM.VALUE(5, 10)); Which creates random string with random length between 5 and 10 characters. Run 10,000,000 times, I got a table with 30 columns and 10,000,000 random rows in no time. "Do not criticize someone until you walked a mile in their shoes, that way when you criticize them, you are a mile a way and have their shoes." Christopher R. Spence Oracle DBA Phone: (978) 322-5744 <FONT size=-1>Fax: (707) 885-2275 Fuelspot 73 Princeton Street North, Chelmsford 01863
![]() |
![]() |