Professional Web Applications Themes

Can CompareNoCase comparing number? - Coldfusion - Getting Started

When my CF application run, 2 variables will be created and their values are compared For example, those variables will have value such as: NewID = 1505 Variable2 = 250 OR NewID= 150 Variable2 = 2511 OR NewID= 101 Variable2 = 101 Before some part of the code is run, I need to compare the Variable2 to NewID and find out whether variable2 has the bigger value or smaller value or the same value. From the book, it says that CompareNoCase is comparing string, does CF has similar function for number comparison?...

  1. #1

    Default Can CompareNoCase comparing number?

    When my CF application run, 2 variables will be created and their values are
    compared For example, those variables will have value such as: NewID = 1505
    Variable2 = 250 OR NewID= 150 Variable2 = 2511 OR NewID= 101 Variable2 = 101
    Before some part of the code is run, I need to compare the Variable2 to NewID
    and find out whether variable2 has the bigger value or smaller value or the
    same value. From the book, it says that CompareNoCase is comparing string,
    does CF has similar function for number comparison?

    alecken Guest

  2. #2

    Default Re: Can CompareNoCase comparing number?

    EQ, GT, LT, LTE, GTE

    Equals, Greater than, Less than, Less than or equal to, Greater than or equal to

    ex.
    <CFIF num1 GT num2>
    <CFOUTPUT>num1 is greater than num2</CFOUTPUT>
    </CFIF>

    - Shawn
    shawnwindler Guest

  3. #3

    Default Re: Can CompareNoCase comparing number?

    Try this:
    jdeline Guest

Similar Threads

  1. comparing Dates
    By Paul in forum Coldfusion Flash Integration
    Replies: 13
    Last Post: June 6th, 09:46 AM
  2. comparing two strings
    By Mattastic in forum Coldfusion - Getting Started
    Replies: 8
    Last Post: November 6th, 09:54 AM
  3. Comparing Time
    By jpesolutions in forum Coldfusion - Getting Started
    Replies: 3
    Last Post: June 25th, 05:41 PM
  4. sort from the smallest number to the highest number
    By Boon Chong Ang in forum PERL Beginners
    Replies: 3
    Last Post: January 30th, 03:00 PM
  5. Comparing two tables
    By mkarja in forum Microsoft SQL / MS SQL Server
    Replies: 2
    Last Post: July 11th, 12:42 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139