Check if qr read value is any data in firebase

I want to connect to this data by reading a data in firebase as text in qr. I took care of this but I have a problem, before I do this I want to see if the value I read is any data in firebase, how can I do that?

I've searched before and found out there is something similar to this but unfortunately it was causing some issues as I was using qr. Can you give information about how to check if data exists with qr in firebase?

Note: I can't debug any of my blocks

Also, because I want a different process, I didn't put the image of the blocks before you said it.

Which data.???

For example, I want to read one of these data with qr and connect to them. But before I do this, I need to check if the value I read with qr is any other value than these.
screenshot.45

Note: Don't be fooled by the 1s, I want it to read what looks like the initial password. I hope their name is data, not variable (I'm a beginner)

That's ok.. but does your QR code contain??

Yep.
screenshot.47

And after developing these codes and reading the qr, I need to check whether such data exists before connecting to the data in my firebase.

screenshot.48

But you have to connect to your data in firebase in order to check whether the (tag) is already there. Looks like you need to call the taglist and check if the qr code is in that list.

I think you are talking about this.

This didn't work and I guess the reason it doesn't work is because it takes all the data but I only read 1 data with the Qr.

Perspective:
The data it receives:

-GUIagsfa
-fguapufg

What I read in the QR:

-GUIagsfa

I can't because you are reading both here, How can I do this exactly and correctly, can you help me please :slightly_smiling_face:

You need the IS IN LIST block.

Please try this simple blocks and let me know the result

image

The logic i used..

After scanning, just call the firebase with scan result. If the tag exists it will print the saved rresult else it will print the what we used in if value not found.. So in firenase got value event, i will read the returned result.. If it returns saved result it mean, that tag exits, if it returnes our result then tag will be stored in firebase which mean no such tag. Instead of reading the whole tags, here we are reading the particular tag

1 Like

This really worked!!:slightly_smiling_face: Thank you so much. Thanks to you, I solved a problem that I could not cope with.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.