Datasets upload via REST API

Following up
If I use the API upload function for files and use the same file name would it just overwrite what is there and keep all the associations with each schema that use it?