title: I want to send one primary key to firebase
body: <p>I want to send primary key to firebase from android phone so I can recognize who send me the data. So basically I'm making an application that will send image to server. I want to check who send me something. So I will need one primary key. Can any one help me out with this? Like how can I send something unique to firebase server? </p>
  
  <pre><code>public  void SignUP(View v){
  
           EditText name = (EditText) findViewById(R.id.editTextRegistrationName);
           EditText contact = (EditText) findViewById(R.id.editTextRegistrationContact);
           EditText city = (EditText) findViewById(R.id.editTextRegistrationCity);
           EditText email = (EditText) findViewById(R.id.editTextRegistrationEmail);
           EditText pass = (EditText) findViewById(R.id.editTextRegistrationPassword);
  
           String userName = name.getText().toString();
           String userContact = contact.getText().toString();
           String userCity = city.getText().toString();
           String userEmail = email.getText().toString();
           String userPassword = pass.getText().toString();
  
           if(isOnline() == true){
               FirebaseDatabase database = FirebaseDatabase.getInstance();
               DatabaseReference myRef = database.getReference("Users").push();
  
  
               DatabaseReference nam = myRef.child("Name");
               nam.setValue(userName);
  
               DatabaseReference contac = myRef.child("Contact");
               contac.setValue(userContact);
  
               DatabaseReference cit = myRef.child("City");
               cit.setValue(userCity);
  
               DatabaseReference emai = myRef.child("Email");
               emai.setValue(userEmail);
  
               DatabaseReference passwor = myRef.child("Password");
               passwor.setValue(userPassword);
  
           }
           else{
                bal.addUser(new UserBean(0,userName,userContact,userCity,userEmail,userPassword));
                Toast.makeText(this, "Data Save in DB", Toast.LENGTH_SHORT).show();
       }
  </code></pre>