Advertisement
Guest User

Untitled

a guest
Dec 7th, 2016
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. var query = firebase.database().ref('ProductCoreDetails');
  2. query.once("value", function(snapshot) {
  3.  
  4. console.log('value of snapshot is', snapshot.val().ProductId);
  5. if(snapshot.hasChild(ProductId)){
  6. console.log('PRODUCT EXIST');
  7. }
  8. else{
  9. console.log('Product doesnt exist');
  10. }
  11.  
  12. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement