Use dbms_random.string to create random string : DBMS_RANDOM « System Packages « Oracle PL / SQL

Home
Oracle PL / SQL
1.Aggregate Functions
2.Analytical Functions
3.Char Functions
4.Constraints
5.Conversion Functions
6.Cursor
7.Data Type
8.Date Timezone
9.Hierarchical Query
10.Index
11.Insert Delete Update
12.Large Objects
13.Numeric Math Functions
14.Object Oriented Database
15.PL SQL
16.Regular Expressions
17.Report Column Page
18.Result Set
19.Select Query
20.Sequence
21.SQL Plus
22.Stored Procedure Function
23.Subquery
24.System Packages
25.System Tables Views
26.Table
27.Table Joins
28.Trigger
29.User Previliege
30.View
31.XML
Oracle PL / SQL » System Packages » DBMS_RANDOM 
Use dbms_random.string to create random string
   
SQL>
SQL>
SQL> exec dbms_output.put_linedbms_random.string'A'20 ) );
iRhhzYvyWLroMPNCvSdx

PL/SQL procedure successfully completed.

SQL> exec dbms_output.put_linedbms_random.string'x'20 ) );
V5HN9YL3C6GJN9BNP4R9

PL/SQL procedure successfully completed.

SQL> exec dbms_output.put_linedbms_random.string'P'20 ) );
w6aH% ZB[3bjH[;x;6h@

PL/SQL procedure successfully completed.

SQL> exec dbms_output.put_linedbms_random.string'l'20 ) );
rjncmdlykahvpgjyecax

PL/SQL procedure successfully completed.

SQL> exec dbms_output.put_linedbms_random.string'u'20 ) );
EHXUUTMYMBAJMHIKKDJM

PL/SQL procedure successfully completed.

SQL>
SQL>
SQL> --

   
    
  
Related examples in the same category
1.ROUND a DBMS_RANDOM.VALUE
2.This script illustrates the use of the DBMS_RANDOM package.
3.Call dbms_random.normal to get a random number
4.dbms_random.value
5.Random string with dbms_random.string
6.Seed a random value with dbms_random.seed
7.Round a random value from dbms_random.value
8.trunc a random value from dbms_random.value
9.mod(abs(dbms_random.random),50000)+1
10.Insert random numbers into a table
11.Insert random value to table
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.