I believe that if you do not have an agreement in force, that a lot depends on the location where the code was written. If the majority of the code was written at the client's site on their computers, then the client has a good case for ownership of the source code. On the other hand, if most of the coding was doen at YOUR business location, and you simply delivered and installed the program and/or updates, the you have a good case for ownership.