Ask a Question related to Macromedia ColdFusion, Design and Development.

  1. #1

    Default Report Builder

    :confused; Okay hopefully somebodey can help me. First one would be the
    simplest. Does anyone know of where to find some detailed expamples of
    Reports for the Report builder? the one that MM ships suck as they don't
    go into a lot of detail on the how and why's. 2. ) here is my problem I have
    a database that returns numbers. so a field called FRT_CHG_CD would return
    either 0,1 or 2 as string values. I then want to do a simple cfif statement
    in report builder that would say if 1 than 'paid' if 2 than 'collect'
    etc. .... I tried writng a simple Report function to do this but the report
    returns somepthing to the effect of cfPackLists2ecfr2015033223$funcP
    OINT@17455ed So could someone tell me or post a sample app that I could study
    to figure out how to make it work? I have figured that either I'm missing
    something so simple or it is difficult.

    <CFIF query.FRT_CHG_CD NEQ "0">
    <CFSET FREIGHT="PAID">
    <CFELSE>
    <CFIF query.FRT_CHG_CD EQ "1">
    <CFSET FREIGHT="PREPAY AND COLLECT">
    <CFELSE>
    <CFIF query.FRT_CHG_CD EQ "2">
    <CFSET FREIGHT="COLLECT">
    </CFIF>
    </CFIF>
    </CFIF>
    <cfreturn freight>

    rcepek Guest

  2. Similar Questions and Discussions

    1. report builder.
      The documentation that comes with the report builder in CFMX7 really sucks. There is not much out there on using the expression builder which has...
    2. CF MX 7 - Report Builder
      Hi Everybody, We installed CF MX 7 Enterprise (multi-server version) on Windows 2003 server. This machine is a dedicated CF server. Do we need to...
    3. Report builder.....
      Is it possible to pass a variable directly to a .cfr or Cold Fusion report? Thanks, Geno
    4. Report Builder (expression builder syntax)
      I'm trying to create a calculated field that will compare the values from one query field and depending on the values will assign a value to the...
    5. CF Report Builder
      I am trying to generate a pricelist report using the new CF 7 Report Builder. When I add an image to the reprt and try to dynamically build the...
  3. #2

    Default Re: Report Builder

    Are you using CF MX 7?
    COLD JOE Guest

  4. #3

    Default Re: Report Builder

    Yeah Currently running CF MX 7
    rcepek Guest

  5. #4

    Default Re: Report Builder

    I have been attempting to solve this myself. I have come up with a work around
    that I doubt is the proper solution but I know it does work and is what I am
    using for now.

    I have made three fields. All that sit on top of each other in the report.
    Then in the expression builder I have set each one to respond if they are the
    proper number. So for example here would be for yours you would have:

    IIf(query.FRT_CHG_CD is "1", de("Paid"), de(" "))

    Then in a seperate field
    IIf(query.FRT_CHG_CD is "2", de("Collect"), de(" "))

    That will print Paid if the FRT_CHG_CD is 1 if not it prints a blank space.
    In the second field it would print collect if it was 2. Obviously it would be
    great to have an else statement but that is the best I can come up with.



    jimpurple Guest

  6. #5

    Default Re: Report Builder

    Thanks for that idea, I tried somethng similar to that, I tried to nest
    multiple IIF statements together but it didn't work. I was really excited
    about finally having a reason to dump Crystal Reports, But I think CF might not
    be there yet. This is such a simple problem that I thought MM would be able to
    correct. Ihope someone frm the forums *hint* can help with this please!

    rcepek Guest

  7. #6

    Default Re: Report Builder

    Where do you have the report function defined? and how are you accessing it?

    First, tag syntax is not supported in the report fields directly. It has to
    be function calls or anything that would be able to be Evaluated by
    ColdFusion (ie in the #MyStuffHere()# syntax or if you used the Evalutate
    function. Everything in an expression essentially has an implicit #..#
    wrapper around it. If you used the Report Function definition part of the
    ReportBuilder, make sure that you correctly specified the return value at
    the bottom. As for usage of said function, you can use it like this in a
    field for example: report.MyFunction(ParamA, ParamB)

    Does that help or answer the question?

    Dean

    "rcepek" <rcepek@resorg.com> wrote in message
    news:cv10mg$6eb$1@forums.macromedia.com...
    > Thanks for that idea, I tried somethng similar to that, I tried to nest
    > multiple IIF statements together but it didn't work. I was really excited
    > about finally having a reason to dump Crystal Reports, But I think CF
    might not
    > be there yet. This is such a simple problem that I thought MM would be
    able to
    > correct. Ihope someone frm the forums *hint* can help with this please!
    >

    Dean Harmon Guest

  8. #7

    Default Re: Report Builder

    I have it defined in the report function editor. with a function name of
    'point', then in the report I call it with an expression called.
    'report.point' below is the exact code that I'm calling from the function
    called point.

    <CFIF #query.FRT_CHG_CD# EQ "0">
    <CFSET FREIGHT="PAID">
    <CFELSE>
    <CFIF #query.FRT_CHG_CD# EQ "1">
    <CFSET FREIGHT="PREPAY AND COLLECT">
    <CFELSE>
    <CFIF #query.FRT_CHG_CD# EQ "2">
    <CFSET FREIGHT="COLLECT">
    </CFIF>
    </CFIF>
    </CFIF>
    <cfreturn freight>

    rcepek Guest

  9. #8

    Default Re: Report Builder

    The news interface doesn't seem to be submitting what I posted, so here goes
    again via the web. The basic modification I made was to pass in the
    query.FRT_CHG_CD to the function instead of trying to use it directly. My
    function is as follows: <cfargument name='FRT_CHG_CD' required='yes'/> <CFIF
    #arguments.FRT_CHG_CD# EQ '0'> <CFSET FREIGHT='PAID'> <CFELSE> <CFIF
    #arguments.FRT_CHG_CD# EQ '1'> <CFSET FREIGHT='PREPAY AND COLLECT'>
    <CFELSE> <CFIF #arguments.FRT_CHG_CD# EQ '2'> <CFSET
    FREIGHT='COLLECT'> </CFIF> </CFIF> </CFIF> <cfreturn freight>
    and the expression of my field is like this: report.point(query.myFieldNameHere)

    Harmeister Guest

  10. #9

    Default Re: Report Builder

    of course the newsreader one comes through when I post the one via the web. :)
    Harmeister Guest

  11. #10

    Default Report Builder

    The Report Builder only runs on Windows, so, will it work with full functionality with Cold Fusion 7 for Linux?:)
    sterlingdking Guest

  12. #11

    Default Re: Report Builder

    The Report Builder itself is a Windows application (initially), but reports created with it can be processed by ColdFusion MX7 on any platform (including Linux).
    BenForta Guest

  13. #12

    Default Report Builder

    Does anyone know if it is possible to do an IF statement to change the font color if the value is less than "0" in coldfusion Report Builder?

    Thanks,
    Brian
    sheridanbman 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