1 Reply Latest reply: Sep 8, 2009 10:40 PM by John Witherspoon RSS

    Set analisys problem

    Jacobo

      Hi all,

      I'm having some problems with a set analisys expression, and i would really appreciate if someone can help me solve
      it. The expression is this one:

      COUNT(
      {$<COD_SIEBEL_ESTANCO = {"=COUNT(
      {1<AGRUPACIONES.FILTRO = {1}, MAESTRO_ESTANCOS_STOCKS.FILTRO = {1},
      PRESENCIA.CLAVE_FECHA = {">=$(#varMinClaveFechaStock)<=$(#varMaxClaveFechaStock)"}>}
      DISTINCT PRESENCIA.FECHA_LECTURA) = $(#varMesesStock)
      "}
      >} 1)

      And the problem is with the dollar sign expasion with the variables in the second quoted part (i've marked them in bold).
      I don't know if its possible to use the expansion dollar in a second quoted part. I've tried this expression to check if
      maybe is not possible to use that kind of expression:

      COUNT(
      {1<AGRUPACIONES.FILTRO = {1}, MAESTRO_ESTANCOS_STOCKS.FILTRO = {1},
      PRESENCIA.CLAVE_FECHA = {">=$(#varMinClaveFechaStock)<=$(#varMaxClaveFechaStock)"}>}
      1)

      But in this case, there was no problem. I would really really appreciate some clarifications or indications.

      Thank you very much,
      Jacobo

        • Set analisys problem
          John Witherspoon

          It IS possible to use more than one dollar sign expansion in the same set analysis expression, if that's what you're asking. I do it all the time, and you yourself came up with an example that worked.

          Perhaps the problem is COD_SIEBEL_ESTANCO = {"=COUNT(...)=..."}. I believe it needs to be COD_SIEBEL_ESTANCO = {"=$(=COUNT(...)=...)"} or maybe COD_SIEBEL_ESTANCO = {$(=COUNT(...)=...)}. But I'm not very confident. That's the part I'd be fiddling around with, though. I'd also break the expression apart into pieces. Can you get just the inside count to work on its own, for instance.