I am having trouble setting a filter on a repeating group. I want the group to show only the new hires (name) incoming in the current month - one name per row.
At the moment this is the closest configuration that I have been able to get to:
Thank you for sharing. Sarah and Helen are saved as custom data type ânew employeeâ, they will not be users. Would following your blog be correct for this?
If you could show me your database, I could guide you better.
If Sarah and Helen are not users and just text saved individually, then a single RG will suffice. The data type of the RG will be âNew Employeeâ and data source will be Do a search for -> Type âNew Employeeâ with constraint Created Date < Current date/time + days:30.
This will get all the entries in New Employee which were created in the past 30 days.
The data type of the RG will be âNew Employeeâ and data source will be Do a search for -> Type âNew Employeeâ with constraint Start Date < Current date/time + days:30.
Ok great - thanks for your help @sharma.himanshu0608. I am still not able to get it to show only one name per line but will play around with it based off your solution.
Is there a reason youâre doing the filtering client-side as opposed to using constraints in the search thatâs specified for the Data source property of the RG?
Iâm not sure I totally follow you. Are you referring to adding the filter to the RG instead of the Text?
There is no specific reason that I am applying the filter where it is at the moment, I am new to bubble so this is my first time trying to add constraints/filters
I was just curious, what does the Search for New employees expression (for the Data source property) look like? Can you share a screen shot? Are there any constraints there?
One approach would be to specify your filter where it says Add a new constraint. That âfilteringâ happens on the server when the data are retrieved from the DB, as opposed to happening in the browser after the data have already been retrieved. Do similarly for ânext monthâ.
Alternatively, you could retrieve 2 months worth of data from the server and then use client-side filtering to split the search results into âthis monthâ and ânext monthâ. That way, the server is being hit just once, and the results are further ârefinedâ (filtered) for each RG after they get to the browser.
Either way, youâd specify start and end dates (either one or two months) in the search constraints.