Ask a Question related to Coldfusion Database Access, Design and Development.

  1. #1

    Default querysetcell on MX

    Hi;
    I am extracting an ODBCdate from an array, and trying to build a Query object
    using QuerySetCell(). I convert the ODBCdate object to a string (using
    dateformat then tried mid() function) but when I insert the string into the
    queryobject, it is reconverted to a {ts date}.

    Any ideas how to force the querysetcell to keep the date as a string? (Yeah I
    know that I can type cast in CF7, but I gotta work with what I have).
    Thanks in advance
    Dale


    odysseus55 Guest

  2. Similar Questions and Discussions

    1. cfc for querySetCell()
      Hi, I would typically write the following code: (See Example A) What I'd like to be able to do is write a CFC that does the same thing but in...
  3. #2

    Default Re: querysetcell on MX

    > using QuerySetCell(). I convert the ODBCdate object to a string (using
    > dateformat then tried mid() function)
    What's the code you've got doing this?
    > but when I insert the string into the
    > queryobject, it is reconverted to a {ts date}.
    Interesting.
    > Any ideas how to force the querysetcell to keep the date as a string? (Yeah I
    CFMX 6.x needs to GUESS (strange; true) what the column type is, and it's
    rally bad at guessing. If you have data in the first row of the query that
    looks like it could be parsed as a date, then it WILL be treated like a
    date. Bleah.

    One question I have... WHY are you trying to store this data as a "string
    that is quite similar to a date" (give CF can still interpret it as a date)
    , as opposed to just leaving it as it is? I'm sure there's a reason, but
    understanding what that reason is could help solving the problem.

    --
    Adam
    Adam Cameron Guest

  4. #3

    Default Re: querysetcell on MX

    I am trying to select on the date field of the built Query object - "where datefield = 'somedate' but MX generates an error.
    I have gotten a work around.

    Thanks

    odysseus55 Guest

Posting Permissions

  • You may not post new threads
  • You may 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