Phil,

I very seldom use cursors; only when values must be evaluated and 
there might be multiple actions taken.

For something like this, I would typically do something like one of 
the following depending on how you are using the data:

Create View ReverseOrder (B, A) +
 as select A, B from OrigTable

or 

Proj NewTable from OldTable using all whe limit = 0

Insert into new Table (A,B,...) select B,A,... from Old Table


No memory problems (I think), less code to maintain, easier to 
understand in the future, etc...

So, do I get the "Glorious Prize" <g>

Ben Petersen


On 25 Jan 2002, at 7:01, Phil Nolette wrote:

> Ben,
> I wish that I would have done that becuase that would have been so much
> easier.  Your are absolutely correct!
> Vulgar or not, it would have saved a great deal of processing especially
> where the two were defined as the same size and type.
> Now crack the problem with memory and you will win a Glorious prize.
> 
> Phil
> 
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of Ben Petersen
> Sent: Thursday, January 24, 2002 6:44 PM
> To: [EMAIL PROTECTED]
> Subject: RE: RB4.5++ with Win2K
> 
> 
> Phil,
> 
> Just a thought, but this sounds like a one time shot.  When you
> say your're trying to "flip" the values of two columns, do you mean
> A=B and B=A? You could just rename the columns. It's a vulgar
> solution, but it'd get done.
> 
> Ben Petersen
> 
> 
> On 25 Jan 2002, at 0:48, Phil Nolette (NCS Group, Inc.) wrote:
> 
> > Albert,
> > I am not using 4.5 but 6.5++ with Win2000 Pro.
> > I have been trying to flip the values of two columns for 90,000 rows of
> data
> > using an update call within a cursor after I have captured the two values
> in
> > two variables.  The problems that I have is almost exactly the same same
> as
> > Steven has stated.
> > After processing about 20,000 rows (390 bytes/row), I get the message:
> > I have a message telling me that the machine is out of Virtual memory and
> > that I should try increasing the size of the paging file.
> > I too have set all my file and buffers to the max.  I run a 1.7Ghz
> Processor
> > and have in excess of 30 GB of physical and max on memory.
> > To counter the problem (slows down to a slug pace), I hit the ESC key and
> it
> > asks me if I want to cancel the command (RMD processing).  I answer yes
> and
> > close down RBase.  I then reopen RBase and run the RMD again and it takes
> > off very fast for about 20,000 rows.
> > Finally my question:
> >    To counter this memory leak, can I put a counter in the code that will
> > count until 15,000 then launch the RETURN /C EXIT.  If you do that,
> doesn't
> > that take you out of RBase?  Then how do you get back in?
> >
> > Phil
> >
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> > Behalf Of Albert Berry
> > Sent: Wednesday, January 23, 2002 2:15 PM
> > To: [EMAIL PROTECTED]
> > Subject: RE: RB4.5++ with Win2K
> >
> >
> > Steven - the memory leak persistence is a chronic problem with W2K.  We
> have
> > added in our menu loops a small command file that checks for the
> > (ENVVAL('COMSPEC')), and if it contains 'WINNT' we do a ZIP RETURN /C EXIT
> > to free up the memory.  We add a pause 3 to tell the user why he/she is
> > losing 3 seconds of their life. They don't like it, but the alternative is
> > worse, so they accept it.
> >
> >
> > Steven Hoggan <[EMAIL PROTECTED]> wrote:
> >
> > >Hello all,
> > >
> > >I apologise profusely in advance for losing my Rbase message archive, but
> I
> > >need help in setting up a Win2000 Pro desktop to run Rbase 4.5++
> > >
> > >I have a set of database maintenance routines that run quite happily
> > forever
> > >and a day under W95/W98.
> > >
> > >Win2000 Pro, however, crashes to the R> periodically, however,  and in
> the
> > >background I have a message telling me that the machine is out of Virtual
> > >memory and that I should try increasing the size of the paging file.
> > >
> > >The details as I have them:
> > >
> > >System stuff
> > >------------------
> > >Dell Dimension 4300
> > >256MB RAM
> > >100GB HDD
> > >Win2000 Pro
> > >Paging File set to 512MB Initial, 768MB Maximum
> > >
> > >System Variables
> > >Files=60
> > >Buffers=60
> > >TEMP=C:\WINNT\TEMP
> > >TMP=C:\WINNT\TEMP
> > >(the above directory definitely exists)
> > >
> > >No User Variables
> > >
> > >Rbase Stuff
> > >----------------
> > >
> > >Rbase Icon settings:
> > >CMD Line: H:\RBASE45.BAT
> > >Memory settings;  All Auto
> > >
> > >Contents of H:\RBASE45.BAT
> > >SET ERR MESS OFF
> > >SET MESS OFF
> > >SET MULTI ON
> > >SET CASE OFF
> > >SET LINEEND = '^'
> > >SET ROWLOCKS ON
> > >CD ..
> > >DISC
> > >SET SORT MAX 64
> > >SET FILES 20
> > >H:
> > >CD \
> > >RUN STARTSYS.MAC
> > >
> > >My Rbase.DAT files has the following 2 settings
> > >SET FILES 20
> > >SET SORT MAX 64
> > >
> > >
> > >Hopefully there's enough there for the experts among you to analyse and
> > >improve upon.
> > >
> > >TIA,
> > >
> > >Steven
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >
> > >Confidentiality Notice
> > >----------------------
> > >
> > >This message and any attachments is confidential and may contain
> privileged
> > >information.  It is intended only for the identified recipient.  Anyone
> > else
> > >must not copy, use, store or disseminate it.  If you are not the intended
> > >recipient, please email it back to the sender and then delete it from
> your
> > >mail system.  Thank You.  Fitzpatricks.
> > >
> > >Tel:  +44 (0)141 306 9000
> > >Fax:  +44 (0)141 306 9090
> > >Web:  www.fitzpatricks.co.uk
> > >================================================
> > >TO SEE MESSAGE POSTING GUIDELINES:
> > >Send a plain text email to [EMAIL PROTECTED]
> > >In the message body, put just two words: INTRO rbase-l
> > >================================================
> > >TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
> > >In the message body, put just two words: UNSUBSCRIBE rbase-l
> > >
> > --
> >
> >
> >
> >
> > __________________________________________________________________
> > Your favorite stores, helpful shopping tools and great gift ideas.
> > Experience the convenience of buying online with Shop@Netscape!
> > http://shopnow.netscape.com/
> >
> > Get your own FREE, personal Netscape Mail account today at
> > http://webmail.netscape.com/
> >
> > ================================================
> > TO SEE MESSAGE POSTING GUIDELINES:
> > Send a plain text email to [EMAIL PROTECTED]
> > In the message body, put just two words: INTRO rbase-l
> > ================================================
> > TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
> > In the message body, put just two words: UNSUBSCRIBE rbase-l
> >
> >
> > ================================================
> > TO SEE MESSAGE POSTING GUIDELINES:
> > Send a plain text email to [EMAIL PROTECTED]
> > In the message body, put just two words: INTRO rbase-l
> > ================================================
> > TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
> > In the message body, put just two words: UNSUBSCRIBE rbase-l
> > ================================================
> > TO SEARCH ARCHIVES:
> > http://www.mail-archive.com/rbase-l%40sonetmail.com/
> >
> 
> 
> ================================================
> TO SEE MESSAGE POSTING GUIDELINES:
> Send a plain text email to [EMAIL PROTECTED]
> In the message body, put just two words: INTRO rbase-l
> ================================================
> TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
> In the message body, put just two words: UNSUBSCRIBE rbase-l
> ================================================
> TO SEARCH ARCHIVES:
> http://www.mail-archive.com/rbase-l%40sonetmail.com/
> 
> 
> ================================================
> TO SEE MESSAGE POSTING GUIDELINES:
> Send a plain text email to [EMAIL PROTECTED]
> In the message body, put just two words: INTRO rbase-l
> ================================================
> TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
> In the message body, put just two words: UNSUBSCRIBE rbase-l
> ================================================
> TO SEARCH ARCHIVES:
> http://www.mail-archive.com/rbase-l%40sonetmail.com/
> 


================================================
TO SEE MESSAGE POSTING GUIDELINES:
Send a plain text email to [EMAIL PROTECTED]
In the message body, put just two words: INTRO rbase-l
================================================
TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
In the message body, put just two words: UNSUBSCRIBE rbase-l
================================================
TO SEARCH ARCHIVES:
http://www.mail-archive.com/rbase-l%40sonetmail.com/

Reply via email to