Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
508 views
in Technique[技术] by (71.8m points)

android - Firebase Database - How to perform a prefix wildcard query

I would like to perform wildcard queries on a Firebase database, and do not know whether the libraries support this. - (my guess it does not.)

I want an optimal solution where the network traffic will be as little as possible, assume the dataset is millions of records.

Dataset (using prefix wildcard):

user_id:
         id_001123:      
                   name: "java"
         id_002124:
                   name: "objective-c"
         id_003125:
                   name: "swift"

How would the code look like to retrieve the record id_002124 name field using a wildcard, you only have a portion of the id. eg. "%124".

The expected result would be id_002124, and the name being "objective-c"

Any mobile language example code would great. (Objective-C/Swift/Java)

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...