Randomly generate the special characters

I want to generate random password which should include at least one special character that could be any special character except @. dbms_random. String ('p', 1) will give 1 printable character that could be all in uppercase or lowercase, or any numeric value too. But how can I generate just 1 special character (with the exception of the @)?


Thank you

Published by: user5406804 on November 4, 2009 05:50

Hello

Welcome to the forum!

You can do something like this:

SELECT     SUBSTR ( '!#$%^*:;,.'               -- list all special characters here
               , dbms_random.value (1, 11)     -- 11 = 1 + number of special characters
            , 1
            )     AS special_char
FROM     scott.emp
;

Tags: Database

Similar Questions

  • where are the special characters in the new Pages?

    where are the special characters in the new Pages?

    Menubar pages: Edit: Emoji & symbols, or control-command + space combination. Same situation in other Apple applications. In addition, available as a menu item from the menu entry in the menu bar to the right, Finder.

  • Hello. Can he the word pdf conversion to retain the original character of the special characters of the algorithm? the formulas have special mathematical symbols. Conversion them kept?

    Hello. Can he the word pdf conversion to retain the original character of the special characters of the algorithm? the formulas have special mathematical symbols. Conversion them kept?

    The equations are a problem. If the equation is text, you can be lucky if you have the fonts on your system. Most of the time I have try, the fonts in the equation are garbage. Expect to have to retype the equations and some special characters. Much also depends on the existence of the fonts on your system. Just in my experience, the equations are almost impossible to convert.

  • How to limit the special characters for a specific column

    Dear gurus,

    I have a table with a field Champ_1 emp

    in this particular Champ_1 is an address column where the data can be as ' 12 st first floor"but suppose by mistake the user has entered data as 12 st first floor & ' must be restricted (not using relaxation but can this be possible using constraints) so for this we can how to restrict the special characters only not to get entered in the column.


    Kind regards
    friend

    Yes you can do it like this

    SQL> create table t (field_1 varchar2(4000));
    
    Table created.
    
    SQL> alter table t add constraint t_chk check(length(regexp_replace(field_1, '[[:alnum:]|[:space:]]'))=0);
    
    Table altered.
    
    SQL> insert into t (field_1) values ('12 st first floor');
    
    1 row created.
    
    SQL> insert into t (field_1) values ('12 st first floor & ');
    insert into t (field_1) values ('12 st first floor & ')
    *
    ERROR at line 1:
    ORA-02290: check constraint (ARBORU.T_CHK) violated
    
    SQL> 
    
  • The special characters in Spanish - what do I need?

    I use Photoshop 7 to create graphics for a series of training which is transposed in Spanish. I use the FCP 6.03 on a G5. What do need me Adobe to create graphics in Spanish? I have access to some of the special characters of the language using the Spanish keyboard - I can see a list of the characters, but how to use the IDs of the unicode characters in Photoshop to show special characters? I can go down the increase? and! and n tilde; accented vowels are not part of the key combinations.

    Scroll down to Mac key combinations:

    http://www.spanishnewyork.com/Spanish-characters.html

  • Laptop keyboard just type the special characters (those of accented)

    My Windows 7 laptop keyboard will only be the type of special characters (for example, accented letters) and no regular letters or symbols. Help please? Laptop is currently unusable because I'm unable to type. Have tried to use as well the built-in keyboard and a wireless and issues is both.

    Well oddly enough it turns out be the key "Alt Gr". How have I never noticed that the key next to the space bar? ! He pressed a couple of times & everything back in order. Thanks to the OP, but because you had not mentioned it I would not have thought to try :)

  • Read the special characters from the txt file

    Hi guys,.

    on blackberry 9000, I tried to read some special characters like this: ° ²® µ±³ ° ¯´µ±´¯® text file

    using this function:

    FileConnection fc = (FileConnection) Connector.open ("file:///SDCard/test.txt", Connector.READ_WRITE);
    InputStream is = fc.openInputStream ();
    InputStreamReader reader = new InputStreamReader (is, "UTF - 8");
    LineReader lineReader = new LineReader (is);
    line & = new String (lineReader.readLine ());

    what I get is different, I can't write it here, it is difficult to find these characters.

    I change the content of the file to:

    ddfdsfdsfdsfdsfdsf
    aaaaabbbc ° ² ° ¯´µ±´¯® µ±³®

    now I get:

    ddfdsfdsfdsfdsfdsf
    aaaaabbbc, then the same characters

    How to display the same as what I have in the text file?

    Thank you

    To add to what martijnbrinkers said, you need not to the InputStreamReader because you don't use it (and this is why your code has no idea that the file is in UTF-8 encoding).

  • Bunch of Oracle on the special characters in a string - translate?

    How to remove special characters in a string, it can contain. , (space), etc.

    SELECT TRANSLATE('123.456 (90-90)', '', '') FROM DUAL
    

    Basically I want to undress and to compare with the db value.

    WHERE TRANSLATE(TABLE.NUMCODE, '', '')  = TRANSLATE('123.456 (90-90)', '', '') 
    

    Use TRANSLATE, since you're on 9i. For example:

    TRANSLATE (your_string,'X,. #! % @$ ^ & * () _-+=', 'X')

    Removes all the s characters in ', #! % @$ ^ & * () _-+=' of your_string.

    SY.

  • Treat the special characters.

    What is the syntax to check whether a character is a special character?

    ... if(myCharacter.contents!=SpecialCharacters.INDENT_HERE_TAB)

    {

    .

    .

    .

    }

    the end of the paragraph is '\r '.

    Substances

  • Why SQL Developer randomly at the end sometimes introduced the special strings?

    I noticed that the SQL Developer has some problems with string manipulation in its code.

    SQL Developer 3.2 when generate us scripts of our efforts using SQL Developer data modeling we often have problems with 'archiving' scripts generated in our SVN repository because he complains about the inconsistency with line endings, and some generated lines have apparently invisible special characters (non-ascii) to the end. The solution is to open the scripts using MS WordPad and save the files immediately, as this text editor would be to filter all characters (not ascii) invisible. So, it wasn't a big deal...

    But now as we explore the SQL Developer 4, we have noticed that we have added to the names of columns during dismantling of 'Table or restore line' operations, special characters effectively corrupted tables (table definitions in the dictionary) that we use in the corresponding unit tests.

    The team SQL developers aware of the problem and if so is there any workaround?

    Please advise...

    Thank you

    Val

    Just a quick update:

    Has obtained another definition of 'corruption' in Toad table after running a unit test in SQL Developer (with the process of disassembly of the table or restore the line) and there seems to be a bug in Toad, not in SQL Developer. The special characters shown in Toad have nothing to do with the actual table definition in the dictionary. After you restart the Toad, the table definition looks good again. Probably a matter of caching in Toad...

    Thank you

    Val

  • How to enter special characters/symbols (i.e. the degree character) in the text boxes?

    Not a problem/w Firefox - I was wondering if there is a way to enter the special characters and characters (not on the keyboard) in the text boxes? I remember that there is a keyboard sequence that activates a context menu allowing the single character/symbol entry. Thanks in advance, Allan.

    See:

  • BlackBerry smartphones getting special characters on the letters: torch

    Normally on a PC, you use the alt key and the number keys to set a certain brand on a letter, that is to say an accent sign an e. How do I do that on my BB torch

    On your torch, with the help of hard slide on the keyboard, press and HOLD the desired accented letter or a special character and do scroll the trackpad horizontally (on the side) and you will see the special characters.

    On the touch keyboard, simply touch and hold the contact for a few seconds and the replacement characters will be displayed, to choose.

  • Why Flash does not generate the names of class not valid for library items?

    I imported a bunch of bitmaps (png).  Library symbol names included the full name of the file and its extension.  When I check "export for actionscript" he generates a class name based on the name of the symbol, and it includes the ".png", even if it is not valid in a class name.

    When I select several bitmaps and choose Properties and export for actionscript, this is a note saying that classnames will be automatically generated for all elements, but it does the same thing... including the ".png" in all class names.  Is this a problem?  It wouldn't save time if Flash would automatically deprive the the name of the instance of bitmap library symbol file extension when generating names of classes?

    Hi James,

    It's how he used to work in Flash CS 6 in which the name of the class generated automatically for any library item used to be the same as the element. Then, you will need to manually fix the name if necessary.

    This behavior has been changed in Flash CC. The names of classes are now generated correctly (special characters are removed, the names of symbols from wit a number get preceded by an underscore and for all bitmaps the extension line getting undress the class name). You can always change the classnames manually based on your naming convention.

    I hope this helps.

    Thank you!

    Mabrouk

  • Special characters in my wpa password can be introduced to officejet J4680c

    I have an officejet j4680c all-in-one, but I don't have a computer at the moment so I use my wireless printer using the application mobile ePrint. Recently, I changed the password wpa, but it includes a dollar sign. When I entered that code is there something I'm missing to this character? Or do I have to change my password again?

    The sign $ is not one of the special characters available for the all-in-one Officejet J4680.  To get this connected device you will need to change this password again to include the characters available on the printer.

    Good luck.

  • Special characters (characters sub) for base as Octal and hexadecimal number systems.

    I would like to add the characters void series of numbers to base such as the Octal and hexadecimal numbers. Is there a function that I can play with my keyboard to get these characters sub? Microsoft Office Word 2007 have only 0, 1, and 2 for base numbers.

    Hello Intrepid02,

    ·         What, exactly, are the special characters that you want to add?

    ·         You want to add them with Office 2007?

    If you want to add special characters with office, the question you have posted is related to Microsoft Office and would be better suited to the Microsoft Office community. Please visit the link below to find a community that will provide the support you want.

    http://www.Microsoft.com/Office/Community/en-us/default.mspx?DG=Microsoft.public.Office.misc&lang=en&CR=us

    Thank you

    Irfan H, Engineer Support Microsoft Answers. Visit our Microsoft answers feedback Forum and let us know what you think.

Maybe you are looking for

  • Satellite Pro U400 and fingerprint software problem

    Hello!Since a long time, my Fingerprint Software gave problems.About 2 days after receipt of the computer, I started to get an error message saying "Specified Database not found" or "Hardware not found footprints" (something similar to messages!) Bec

  • Qosmio G10: Blue screen shot and later endless reboot

    Hello! I found similar topics on this problem, but they were locked and left unanswered. My problem is this: I have not changed of _anything_ in the BIOS for a log time. I have not installed new software or hardware lately. And I have not damaged my

  • Clock screen locking problems

    My lock screen clock is not update indicates 6 no h no mater what time it is and show that it is killing when it is actually Tuesday.

  • Zoom in & out while using the pointer - this function can be disabled?

    Hello all - I need help please. Most of the time when I use my new HP laptop, while I use the mouse Touchpad Square that moves the pointer on the screen, often, sometimes the screen zoom in or out. I found a function of zoom on the laptop, but I can'

  • Aurora-R5, double video cards, different models?

    I bought a r5 aurora and there a Nvidia GTX 1080 8Gb I would like to know if I wanted to put another card NVidia should be an another 1080 or I can put matter I want cos I have other r2 of alienware x 51 with a NVidia GTX 960 just wonder if my alienw