{smcl}
{* 20nov2001}{...}
{hline}
help for {hi:sjutil}{right:{net "from http://www.stata.com/users/wgould":http://www.stata.com/users/wgould}}
{hline}

{title:Install and uninstall entire issues of the Stata Journal}

{p 8 19}
{cmd:sjutil}
{cmd:install}{bind:   }{it:volume_#}
{it:issue_#}
[
{cmd:, replace}
]

{p 8 19}
{cmd:sjutil}
{cmd:uninstall}
{it:volume_#}
{it:issue_#}

    Example:     {cmd:. sjutil install 1 2}

{p 4 4 4}
The above installs software associated with volume 1, issue 2.  The volume
and issue may be typed typed a variety of way, including

                 {cmd:. sjutil install 1(2)}
                 {cmd:. sjutil install 1-2}
                 {cmd:. sjutil install 1.2}
                 {cmd:. sjutil install 1:2}


{title:Description}

{p}
{cmd:sjutil} installs and uninstalls the software associated with entire
issues of the {it:{help sj:Stata Journal}} from 
{net "from http://www.stata-journal.com/software":http://www.stata-journal.com/software}.

{p}
Typing {cmd:sjutil install} more than once for the same issue is safe.  In
that case, {cmd:sjutil install} will step through the inserts one by one and
tell you that "all files already exist and are up to date".


{title:Options}

{p 0 4}
{cmd:replace} specifies that if a file in an insert is already installed -- if
    the file is duplicated -- the new file is to replace the old.  If you do
    not specify this option, inserts with duplicated files will not be loaded.

{p 4 4}
    If you load {it:Journal} software in order -- you install, say, 1(3) after
    1(2), 1(2) after 1(1), etc., you are advised to specify this option.

{p 4 4}
    Pretend 1(1) contained software dm0001 and that, later, 2(3)
    contained an update to dm0001 called insert dm0001_1.  It would hardly
    be surprising that dm0001_1 contained some of the same files as the
    old dm0001.  Now let's pretend that you have already installed
    1(1), meaning dm0001 is installed.

{p 4 4}
    If you went to install dm0001_1 {it:interactively}, you would immediately
    discover that dm0001_1 overlapped dm0001 and, considering the problem, you
    would probably uninstall dm0001 and then install dm0001_1.

{p 4 4}
    If you use {cmd:sjutil install}, you are mindlessly installing all the 
    {it:Stata Journal} software.
    Specifying {cmd:replace} tells {cmd:sjutil install} to use the newer files
    in preference to the old.  {cmd:sjutil install} will not uninstall the
    original, but that will not matter.  Stata will not become confused.  Even
    if you went back and uninstalled the original dm0001 later, Stata would
    know not to uninstall the dm0001_1 files.  Stata is very smart about this.

{p 4 4}
    Now pretend you installed entire {it:Journal} issues the other way around.
    You have previously installed the entirety of 2(3) and now go to install
    1(1).  You have dm0001_1 installed and, if you specified {cmd:replace},
    you would be telling {cmd:sjutil install} to replace the contents dm0001_1
    with the older dm0001.  Presumably, you would break something more modern.


{title:Examples}

	. {cmd:sjutil install 1 1}
	. {cmd:sjutil install 2 3, replace}
	. {cmd:sjutil install 2(4), replace}

	. {cmd:sjutil uninstall 1(3)^}


{title:Author}

William Gould, StataCorp.


{title:Also see}

{p 0 19}
On-line:  help for {help sj}, {help net}
