It would be helpful if you'd describe your scenario in concrete terms; what happens in your “app”, what does “return repeatedly” mean etc.
The application is designed to control customer flow into an office. The service offers several therapy sessions. Customers come in initially for a session type A or B and that is simply tracked Session A 1 or B1 - that is workin in the application. Then the first time a customer comes back to the session type A or B, that initiates a series of "office returns" for specific sessions which I've called Return A or B. The same customer might come back for different types of sessions (A or B type) in different days of the week. I need to keep track of each time the customer comes back in and register the "Return number" under that same customer for each specific type of session. So you could have in the same week Customer Mary coming back for session type A and that should read Return 1 A, then she will be back later on in the week for session type B and that should read Return 1 B, and so on. You could have the same customer returning 20 times to session A and only 12 times to session B. That tracking is important because after a prescribed number of sessions he/she will have to undergo a new screening for follow-up and redirection.
I've tried to do it via the creation of a specific field in each table that has the returns (Return A and Return B)
I think you should have a single Sessions table, with a type field (A or B [C, D, E …?]); when creating a new session for a given type, check if (and how many) sessions of that type already exists, then number the new one accordingly (new return number = count of existing sessions of that type).
Depending on your workflow for creating new sessions, you could either use an auto-enter calculation (e.g. a self-join of the Sessions table as id_customer =id_customer and id_type = id_type, or an equivalent ExecuteSQL() query), or set the value via script (count the number of the new type in List ( Sessions::type), and increment the result).
Not a bad idea! I will try that. Thanks!