当我从firebase检索数据时,我根据他们的uid检索我想要检索的每个用户的第一个数据
if Auth.auth().currentUser != nil{
let queryRef = Database.database().reference().child("Details")
//here, its getting the u id
let userID : String = (Auth.auth().currentUser?.uid)!
print("Current user ID is" + userID)
self.databaseHandler = self.readData.child("Details").observe(.value, with: { (snapshot) in
self.postData = ((snapshot.value) as? [String : AnyObject]!)!
//print data to see if you require
//print it to generate loop for required things
print(self.postData)