Clarification on built-in commands

Note that StataCorp does not allow modifications to their Stata's built-in commands by the users. It is technically possible to let the user supply a custom procedure to handle conversion of the unknown types of files, but this conversion process:

Hence data conversion is usually a separate step before data processing.

In most cases converting the dataset manually with use13 and storing the converted file to process it later is the preferred mode of operation. However in some systems the files may be generated automatically and for example downloaded from a remote system for processing.

use

Specifically, this means that you should not expect that after installing use13 you will be able to e.g. load the Stata 13 data in e.g. Stata 12 with the same command, such as use "file13.dta". Stata still stop with an error 610 "file not Stata format" and this is a normal and unavoidable behavior. Instead you must write use13 "file13.dta".

append

Similarly, but perhaps not as obviously, the other Stata's commands (append, merge, etc) will not know anything about the new format, and installation of use13 will not change it. The code of the append command will not be affected in any way, but instead, as described above, you will need to do a two-step process of converting the file first, then executing the actual command. For example, to append a Stata 13 file:

tempfile tmp
preserve
  use13 "C:\My Data 13\auto.dta", clear
  save "`tmp'"
restore
append using "`tmp'"

We can even envelop this code into a new program of its own:

program define append13

  syntax using filename, [*]

  tempfile tmp
    preserve
      use13 "`0'", clear
      save "`tmp'"
    restore
  append using "`tmp'", `options'
end

This primitive command does not support the file list for appending, which was added in Stata 11. There is no problem to do that too. Append is an .ado file, and viewsource append.ado would reveal it's implementation. Each of the two calls to _append should be prepended with the conversion code, similar to illustrated above. If you care about efficiency, more efficient ways to do it exist, but there is no point to pursue them as use13 is seen only to feel in the temporary capability gap.

It is not recommended to replace any commands supplied by StataCorp with any custom modifications, unless you really, really, really know what you are doing. Hence the above command is named append13 and not append, since then it might affect the performance of other parts of the system, which utilize append.

merge

To merge current dataset with a Stata 13 dataset:
tempfile tmp
preserve
  use13 "C:\My Data 13\auto.dta", clear
  save "`tmp'"
restore
merge make using `"`tmp'"'

You will need to sort data just as you normally merge the datasets that Stata understands natively. Note that use13 preserves not only the order of observations of the original dataset, but also the sort order of the original dataset! You do not need to re-sort the converted file before the merge if it was already sorted.

The only exception to this is when the sort key included a strL variable or a strF variable that can't be accommodated in Stata 12 and earlier (longer than 244 characters). Then sorting key will change. But you would need to re-sort the data anyway. The order of observations in the converted dataset never deviates from the original.

Other built-in and user supplied commands

For all other commands the principle is the same, if a command requires a dataset name on disk as a parameter, convert that file from Stata 13 format before running this command. Use tempfiles whenever possible if you are doing it on-the-fly (without storing the converted dataset).