firebase.database().ref('items/').orderByChild('letter').on('value', snapshot => { snapshot.forEach(c => { i = c.val(); console.log(i.number, i.letter, i.date) }) })