Skip to Content
avatar image
Former Member

Two Fields in a Single Table

Hello All,

I'm a newbie to the forum & to Crystal(9), I've searched the forum and ca't exactly find an answer to my question:

My goal is to be able to pull the Company Member Type & the Contact Member Type as part of the same report in the selection criteria.

My problem is: They both reside in the same table...

The question is: "how to be able to pull the info?"

If I need to provide more or clearer info pleasde let me know. Any help is appreciated.

Lost in DC - DJ

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    avatar image
    Former Member
    Oct 16, 2008 at 02:51 PM

    Hi DJ,

    Please try this :

    not isnull(Company Member Type) and not isnull(Contact Member Type)

    Thanks,

    Sastry

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Oct 16, 2008 at 04:10 PM

    Hi DJ,

    I think I didn't understand what exactly you are trying to get. If both are from the same table then you can add the cindition like

    {Company Member Type}="abc" 
    and
    {Company Member Type}="xyz"

    you can also try this

    {Company Member Type}="abc" 
    or
    {Company Member Type}="xyz"

    place this in record selection formula.(Report >Selection formulas >record)

    Regards,

    Raghavendra

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Try this,

      {Activity.PRODUCT_CODE} = "ASP" and

      {Name_Address.PREFERRED_MAIL} and

      ({Activity.ACTIVITY_TYPE} = "SP_PART" OR

      {Activity.ACTIVITY_TYPE} = "GIFT")

      if you are still getting the duplicate records then try to use supress condition on section expert something like this

      field=previous(field)

      also you have one more condition like

      right click on the object >go to format field >check the option supress if duplicated for all objects.

      Regards,

      Raghavendra

  • avatar image
    Former Member
    Oct 17, 2008 at 07:00 PM

    If you have a single table datasource record duplication wouldn't be a result of the select expert. In fact, I can't think of a case where a single table datasource could possibly duplicate records.

    The duplicates must be the result of a join.

    To answer your initial question, the select expert you enter is subjected, in its entirety, to each record in the joined tables.

    The problem that I see with the above suggestion relates to precedence.

    This:

    cond 1 AND cond 2 AND cond 3 OR cond 4

    Is not this:

    cond 1 AND cond 2 AND (cond 3 OR cond 4)

    In the case of the non-paren-ed select statement, it will return records that satisfy ALL of the AND conditions OR just the or condition.

    In the second case, it will return all records that satisfy condition 1 and condition 2 AND either condition 3 or condition 4.

    Try bracketing the ored conditions from the same table. That should solve your select problem, but not the duplication problem.

    Add comment
    10|10000 characters needed characters exceeded