Skip to Content
avatar image
Former Member

How to count appointment one time

I am trying to do a count on Patient name and date.

I am trying to add these 2 as one formula field that I can do a count on.

({DDB_APPT_BASE.APPTDATE}) + ({DDB_APPT_BASE.PATNAME}))

but I get a message on the second one that it's 'not part of the formula'.

We have a patient appointment table and sometimes the same visit is in there more than one time, due to billing or whatever. I am trying to count as one visit if the patient name is the same and also the datetime. I also have main group by Dentist. But the key is these 2 fields. I dont see how I can count this otherwise.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    Jul 27, 2017 at 10:35 PM

    You can't concatenate fields with different types. In your case Date type + String type.

    but you can convert the Date to Text and then concatenate:

    Totext ({DDB_APPT_BASE.APPTDATE}) + ({DDB_APPT_BASE.PATNAME}))

    Add comment
    10|10000 characters needed characters exceeded