Date: Thu, 3 Oct 2002 07:32:51 -0400
Reply-To: Raynald Levesque <rlevesque@videotron.ca>
Sender: "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From: Raynald Levesque <rlevesque@videotron.ca>
Subject: Re: how to close the file via syntax
In-Reply-To: <005501c26ab6$f2113000$57fa4c3e@unn.runnet.ru>
Content-type: text/plain; charset=koi8-r
Hi
Try the following:
Add a SAVE OUTFILE='c:\temp2.sav'.
before the COMPUTE nobreak=1.
See also
http://pages.infinit.net/rlevesqu/DebuggingSyntax.htm#FileIsUsed
HTH
Raynald Levesque rlevesque@videotron.ca
Visit my SPSS Pages http://pages.infinit.net/rlevesqu/index.htm
-----Original Message-----
From: SPSSX(r) Discussion [mailto:SPSSX-L@LISTSERV.UGA.EDU]On Behalf Of LRS
Sent: October 3, 2002 4:29 AM
To: SPSSX-L@LISTSERV.UGA.EDU
Subject: how to close the file via syntax
Hi,
I use the syntax of kind that I found in Raynald's site (see below). I need
to run it several times in a syntax file and I whant to use the same
temporary file (c:\temp.sav) each time. However, when I run this syntax
second time (starting from "COMPUTE nobreak...", without redefining data)
the error occures (Error # 62 in column 19. Text: c:\temp.sav >The file is
already in use.) I suspect that I have to close somehow the file c:\temp.sav
to proceed, but how to do that?
Thanks in advance.
Anton Balabanov,
Chair of Applied Statistics, Assistant
University of Nizhny Novgorod, Russia
DATA LIST LIST /x y.
BEGIN DATA
2 5
3 3
4 4
END DATA.
LIST.
COMPUTE nobreak=1.
AGGREGATE OUTFILE='c:\temp.sav'
/BREAK=nobreak
/maxy=MAX(y).
MATCH FILES FILE=*
/TABLE='c:\temp.sav'
/BY=nobreak.
COMPUTE z=x/maxy.
EXECUTE.