Regular expression to allow only numeric characters or spaces in the num field such

Hi people

Am Newbie Apex using 4.0.1 / Vista / Oracle XE and am trying to create a level validation element on a phone number field

I want any combination of numbers and valid spaces with only the obvious condition that the field cannot be completely spaces.

Can anyone help to suggest how to do because I'm really bad with something so simple that I have no exp prev reg expressions.

Thank you, as always
Peter

Hello
It's quite strange, I just tried your entry (without apostrophes) and it passed. Do you have you copied my reg exp (a ^ $ included) and pasted into the Expression of Validation 2 field validation with regular Expression of type? We must really work.

Jirka

Tags: Database

Similar Questions

  • Phones unlocking password box smart blackBerry. Keyboard allows only numeric characters.

    I choose aA which is at the top right, but this disappears 123 boxes and in the top right of the screen is displayed when you try to unlock the keyboard.  The 123 box does not turn off when the unlocking password box is displayed. Alphabetic characters in my password may not be seized at all from the table, only those digital.

    I can't unlock and therefore to use the phone.

    I removed the battery and restarted a couple of times without change.

    Ideas welcome!

    drmarkpenney wrote:

    The problem is only with the normal box saying "Enter PIN Code".

    There is your idea, he wants the PIN SIM lock code, it does NOT have a password, I promise you.

    If you do not know your PIN, call O2 and ask. It's NOT the same as a smart phone BlackBerry PIN (which is eight alphanumeric characters. He wants a digital code to four digits.

    Believe me. Summer is here.

  • The z570 has not a regular Express card slot (only a mini one)?

    The z570 has not a regular Express card slot (only a mini one)?

    Hi KiteEye and welcome to the community,

    It doesn't have an Express card slot.

    The small slot located is a memory card reader.

    Dave

  • I'd do the signature field read only until something is entered in the required fields.

    I'd do the signature field read only until something is entered in the required fields.

    Attached a sample file that has two text fields and field of signature, the signature field allows only when certain values are typed in two text fields.

    Steps to achieve this:

    (1) disable the signature field when the form is loaded

    (2) to activate when the two text fields values are not null

    Santosh-

  • I have an annual subscription to Adobe CC, but I have only 2 GB of space in the cloud, why is this?

    I have an annual subscription to Adobe CC, but I have only 2 GB of space in the cloud, why is this? I was told that in 2 days they have contacted me, but it been 3 days and still have no response to my problem.

    adobe cc.PNGadobe cc2.PNG

    I have reset the 20 GB storage, please disconnect & reconnect the CC desktop application & check the storage quota.

    Concerning

    Stéphane

  • Regular expression matching receives only two digit in brackets

    Hello

    I use the regular expression of the correspondence with the following expression. It is only able to get all the numbers that are not mere numbers. I want to retrieve all the values which lie between >< in="" the="" string="" and="" create="" an="">

    Then

    182
    2

    would be output

    182

    2

    Any help would be appreciated. I've attached what I have so far. Right now I still have the >< and="" it="" can="" only="" grab="" numbers="" that="" are="" not="" single="">

    Use (>.) [ ^(<>)]*)<    *="" instead="" of="">

  • Regular experssion Unicode: allowed only numbers and letters

    What is the best way to write the query that generates the data according to the rules:
    (1) input string may include only numbers or letters, other symbols are not allowed,
    (2) numbers must be positive integers together: 0. 9 paper, no point or a comma or a space allowed in numbers.
    (3) letters may be lower or uppercase, regardless.
    (4) letters/characters may come from an English alphabet and can come from an Estonian alphabet, see BOF MCet alphabet letters he
    http://en.Wikipedia.org/wiki/Estonian_alphabet
    Thus, the symbol of the alphabet "Has two chief points" must also be accepted. Would be preferable that the German alphabet is allowed too and any alphabet is allowed, if possible.



    The initial request, I did is like this:
    with t as (
     select '01A' str from dual union all--ok
     select '1,1' str from dual union all--not ok
     select '1.1' str from dual union all--not ok
     select 'F' str from dual union all--ok
     select '1' str from dual union all--ok
     select 'Ä3' from dual union all--ok
     select 'a 3' from dual union all--not ok
     select ',4Ca.' from dual--not ok
     
    )
    select * from t where regexp_like(convert(str,'us7ascii'), '^[a-zA-Z0-9]+$')
    /*
    01A
    F
    1
    Ä3
    */
    I was failed when I tried to use this character class:
    "[: alnum:] any alphanumeric character from 0 to 9 OR A to Z or a to z."


    My environment:
    (1) "oracle Database 11 g Enterprise Edition Release 11.2.0.1.0 - Production.
    (2) NLS settings can change, depending on the client session, sometimes NLS_LANGUAGE have 'ESTONIAN' value and for some sessions, there is another value, same goes for the other nls settings I think.

    --
    Without "convert" - function I loose the record with "A 2 Chief points", which is bad:

    with t as)
    Select "01" a str of all - double union ok
    Select '1.1' str of all double union - not ok
    Select ' 1.1' any double union str - not ok.
    Select 'F' str of all - double union ok
    Select '1' str of all double union - ok
    Select "3" h.t. of all - double union ok
    Select ' a 3' of all - double union not ok. "
    Select ', ca. 4' double - not ok

    )
    Select * from t where regexp_like (str, ' ^ [a-zA-Z0-9] + $')
    /*
    01 A
    F
    1
    */

    Why don't you use it?

     select * from t where regexp_like(str, '^[[:alnum:]]+$')
    

    I was failed when I tried to use this character class:

    I do not see any problem in using alnum. Tell us what you have got everything using the error.

    Kind regards
    Prazy

  • InDesign Page allowed only eight characters article?

    In the page of my document with the prefix to more than eight characters. How to handle this scenario?

    example of number of myPage = 475, 1-23, 1-75

    Pagno = 1

    prefix: 475, 1-23, 1-75, 1

    Please advice. Adobe needs to fix this.

    This is the limit. Yes. You can't do anything.
    Other than to request a feature and hope for the best.

    Work-around would be possible.
    Change the content of the page on every page of script name according to your rules.
    But it is not flexible.

    Kind regards
    Uwe

  • Check that only one box to advance to the text field

    I work in Acrobat Pro ms, I created a form and I have the following problem. The application form concerning the rental income, either monthly or annual (the format is less).

    What I want to happen, is if possible, if the user clicks on the checkbox monthly (monthly) the cursor goes to the 2 text and the user has entered the monthly amount.

    If the user clicks on the annual check (per year), the cursor goes to Text1, the user enters the annual amount. This amount is automatically divided by 12 and shows in the Text2 text field; and the cursor goes in the following text, Text3 field.

    Naturally, I don't want the user to click on the two boxes, but I don't know that the coding would take care of that, just do not know how come with the coding.

    £ Rental income monthly

    £ Annual if, Yes $ Text1 / Text2 $12

    Thanks for the help.

    You have 3 separate issues here:

    -Exclusive box

    -Jump to another field

    -Calculate the monthly payment

    -Exclusive box: you must give the two fields of the same name (say "times"), but the different export value, say "Monthly" and "annual".

    -Jump to another field: As the MouseUp event of the 'Monthly' box enter this script:

    this.getField("Text2").setFocus();
    

    As the event MouseUp "Annual" box enter this script:

    this.getField("Text1").setFocus();
    

    etc.

    -Calculation of the monthly payment: so you want this value to be entered by the user if the "Monthly" option is enabled, but being calculated if the "Annual" option is selected? It's a little complicated to implement in a single field, but you can try to use something like this as the "Text1": custom validation script

    if (event.value && this.getField("RentalPeriod").value=="Yearly")
         this.getField("Text2").value = Number(event.value)/12;
    
  • Use matching of regular expressions to search for parentheses

    Hi all

    I am currently looking for a particular pattern in a string, I can't display the exact string, but say its something like that.        corresponds to regular_pattern (5000): 0

    I'm also looking for the a different model at the same time, so I have to use the corresponding regular expression and the | function.  I can't understand how to match this model because the regular expression function allows parentheses unless I put them in the legs, and that does not help me for this.

    Any advice?

    Thank you

    Matt

    Have you tried to escape the bracket?

  • Regular expression matching is not what matches Pattern

    I read a lot of posts on how match model does not match what match regular expressions will be due some characters does not.

    However, I found a problem with the other way. A simple Reg - Ex who works in the match pattern but not regular Expression match.

    What I have here is just an example. I want to use regular Expression Match then I can specify some matches under.

    The reg - ex's: one or more non-numeric characters, a space, one or more numeric characters. At the beginning of the string.

    How can I get this to work in regular expression matching? I work in LabVIEW 2010f2 32 bit. Here is the code snippet and the results:

    Rob

    One of the subtle differences is the operator of negation for the character classes.  In match pattern is ~, but for the Match RegEx is ^.

  • AFExactMatch and regular Expressions

    Hello

    I'm working on something similar to this http://forums.adobe.com/message/4215772#4215772.

    My first shot at it.  Found it useful messages of try67 and George.  I'm almost there and now, I'm stumped.

    My Custom Format Script is the following:

    Custom Format script for the text field

    If (event.value) event.value += '% ';

    My typing a custom Script is the following:

    Custom keystroke script

    DigOnlyKS();

    My custom calculation script is the following:

    If (event.value == "") event.value = 0;

    My Javascript Document is:

    function DigOnlyKS() {}

    Get everything that is currently in the field

    var val = AFMergeChange (event);

    Refuse entry if other thing that the figures

    Event.RC = AFExactMatch (/ \d* /, val);

    Event.RC = AFExactMatch (/^100\.0| [1-9] {1,2}\.\d{1}|0\.\d{1}$/, val);

    }

    Valid entries must be: 100.0, 1.0 to 99.9, and 0.1 to 0.9.

    The regular Expression seems to work on the Regex testers online.

    However, I can't enter anything in the field with the foregoing.

    If replace my Regex with the link above - ^ \d+\. ? \d{0,2}$ - I can enter data in the field.

    However, if I remove the? the - ^\d+\.\d{0,2}$ - regex to require (I think) the decimal places, I can't enter anything in the field.

    Clearly, Miss something.

    Thank you.

    Regular expression is not appropriate for a typo script until the value has been committed, and even in this case, it may be too restrictive (for example, does not allow for ".") 9 »).

    The way I would be inclined to implement would be to put the strike and Validate Format (not calculate) scripts to call the following functions, respectively.

    // Custom Keystroke script calls this
    function percent_ks() {
    
        AFNumber_Keystroke(1, 1, 0, 0, "", false);
    
    }
    
    // Custom Format script call this
    function percent_fmt() {
    
        AFNumber_Format(1, 1, 0, 0, "", false);
        if (event.value) event.value += "%";
    
    }
    
    // Custom Validate script calls this
    function percent_val() {
    
        if (event.value === "") event.value = 0;
    
        // Only allow numbers from 0 to 100
        if (+event.value >= 0 && +event.value <= 100) {
            // round to nearest tenth
            event.value = util.printf("%.1f", event.value);
        } else {
            event.rc = false;
            app.alert("Your error message goes here.", 3);
        }
    
    }
    

    It lets you enter values outside the valid range, but the validation script takes care of it. It also allows more than one digit to the right of the decimal, but the validation script it rounds up to the tenth closest. Make sense?

    Edit: correction of fault

  • Regular expression to remove a single carriage return character

    Hi all

    What is the regular expression to remove only one character to return to a text string. I have something like this:

    1

    (two returns)

    2

    and I want to delete only one of the characters turn it over so I'll go

    1
    2 (one after the other

    I know / r but ot deletes all of the text string.

    Thanks a lot for any help

    Try something like:
    (in my message window):
    s = "a" & RETURN & RETURN & "two".
    placed s
    l = [s]
    put re_replace (l, "(?)")<=\r)\r", "g",="">
    Place the [1]
    (exit):
    -"a".

    two ".
    -1
    -"a".
    two ".

    I don't know how effective the situation described above could be for research, but
    You can also try:
    put re_replace (l, "\r\r", "g", RETURN)
    or:
    put re_replace (l, "\r{2"}, "g", RETURN)
    However, these last 2 only work in the situation where there
    exactly 2 returns you want to replace with a single DECLARATION - the first
    replaces any number of multiple returns with one RETURN

    It is possibly more effective than the first - it will replace again
    all multiple with a single; but it will unnecessarily replace one
    RETURN character with one character in RETURN - but I'm not a regular expression
    Expert:
    put re_replace (l, "\r+", "g", RETURN)

  • Complex regular expressions without multiple passes

    Does anyone know of a tool that can handle more complex regular expressions without chaining of multiple copies of the VI regular expressions?

    For example, if I have a XML string as

    Power supply error has occurred.

    Sorensen SGA166/188

    and I am interested in the tag method to retry only, I could write a regular expression something like

    .*.*

    to parse the string inside the tag.

    kc64 wrote:

    For example, if I have a string like

    My email address is [email protected].  Please no spamming not me.

    and I am interested in the domain name of the email only address, I could write a regular expression something like

    @(\w)*\. (com: net | org)

    to parse the string 'gmail '.

    Forgive me if I am away from base, but I'm flying blind at the moment (not LV to test what I say).  You can add to the power of a regular expression using submatches or capture groups.  The regular expression you wrote will grab (I think) @gmail.com for the entire game.  Let's say you want to get 'gmail' without a second function call.  You can do the first group of a little dishonest selection by moving the * inside the parentheses.  Then, on the BD pull down on the bottom of the function of regular expression matching to expose a variable number of submatches (both should be in this case).  The first should be 'gmail '.   The second one should be "com."

    In summary, @(\w*)\.) (com: net | org) should give you gmail in the first submatch.  Of course, my Perl is a little rusty and LV cannot apply in the same way.

  • Search for a string using "Game Plan" or "Regular Expression to Match."

    Hello

    I would use the 'game plan' or the vi "Expression regular game" simply because the products that provide these vi. The result that interests me is the substring 'after '. I want to be able to specify a "substring" and get everything after the substring of the input string. However, I'm getting all confused and/or watered upward when it comes to "regular expressions". Is there a way to create a "regular expression" which acts as a 'substring' to find within the input string?

    The substring is a path of partial directory that contains a colon, backslashes, etc. which are part of a directory path.  If some how the "regular expression" entry must ingnore all special characters and simply to understand if the substring in the string entry and give me 'all things' after the substring in the output of 'after the string.

    Use Regular Expression Match instead of match pattern; It's better.

Maybe you are looking for