External collection creating duplicate database records

Hi Cool People. I am running dynamic search on an external database. And once a User clicks on a result, a record is created in an Adalo database. I’ve watched the videos from @Victor and @theadaloguy about setting up conditional logic & disappearing buttons but that isn’t working in this case.

Here is the conditional logic settings:
Create Internal Record SOMETIMES… IF
Custom Filter:

  • All Internal TV Database > Count
  • Is equal to
  • All tmdb (external collection search) > Count
  • Is equal to
  • 0 (zero)

I’m sure it’s user error. What am I missing?

I don’t understand why you have equal to zero at the end. I don’t think you need that?

I thought that meant IF the Adalo DB doesn’t not contain the TMDB (external) record then create one.

Eg. do the back end search. If zero records exist, create one.
Is that not correct?

I also tried to – Create record SOMETIMES if Internal DB Count is not equal to External tv show ID. – no luck with that either.
Screen Shot 2022-03-09 at 9.53.36 PM

I couldn’t stop the duplicates from happening so to solve this, I changed how the comments/recommendations are filtered. By filtering with the tv_id (integer) the number of records don’t matter. Only the recommendations by tv_id do.

Definitely a short term patch. But it keeps the project moving forward…

Screen Shot 2022-03-15 at 11.12.57 AM

Thanks for all the help and thought everyone! :slight_smile: