Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #5835

Re: Records not updated using Upper()

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail
From Karl Wochele <kw@e﹐s-system.dot.de>
Newsgroups comp.lang.clipper.visual-objects
Subject Re: Records not updated using Upper()
Date Tue, 17 Sep 2013 15:53:06 +0200
Lines 42
Message-ID <b9r563FduniU1@mid.individual.net> (permalink)
References <b56d351a-0c60-4d6b-ab57-7dbce206000f@googlegroups.com>
Mime-Version 1.0
Content-Type text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding 7bit
X-Trace individual.net xmBrkevbutlIykpC9j1RSwAZExDDbOeHwO9J1ivxlKIYyH9ioi
Cancel-Lock sha1:0+RtmU+7bA4KrVxcQgT/6aNYQP8=
User-Agent Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130801 Thunderbird/17.0.8
In-Reply-To <b56d351a-0c60-4d6b-ab57-7dbce206000f@googlegroups.com>
Xref csiph.com comp.lang.clipper.visual-objects:5835

Show key headers only | View raw


Hi Rob,

you should insert oServer:Setorder(0) before oServer:gotop()
If you change the KeyValue of the current record your next skip might 
take you anywhere, even to eof() ...

HTH
Karl

Am 17.09.2013 15:42, schrieb Rob van Erk:
> I have a DBF with upper and lower case data in field COMPNAME. I need to uppercase all data in that field. The DBF's allows duplicate records and the index is on COMPNAME. The following code refuses to change contents of COMPNAME to uppercase for the first record
>
> COMPNAME
> ========   => output:
> artmcxa01  artmcxa01
> artmcxa01  ARTMCXA01
> artmcxa02  artmcxa02
> artmcxa02  ARTMCXA02
> artmcxa03  ARTMCXA03
> artmcxa04  ARTMCXA04
>
> Why is the first record not changed to uppercase?
>
> Code:
>
> local sComp as string
>
> oServer:= DSComputersImport{}
> oServer:Zap()
>
> oServer:Appenddelimited("c:\snow\computers.csv",",")
> oServer:GoTop()
>
> do while !oServer:EoF
>     sComp := upper(oServer:FIELDGET(#compname))
>     oServer:FIELDPUT(#compname, sComp)
>     oServer:Skip(1)
> enddo
> oServer:Close()
>
> Thanks for any advise to solve this issue.
>

Back to comp.lang.clipper.visual-objects | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Records not updated using Upper() Rob van Erk <erk.v@hotmail.com> - 2013-09-17 06:42 -0700
  Re: Records not updated using Upper() Karl Wochele <kw@e©os-system.dot.de> - 2013-09-17 15:53 +0200
  Re: Records not updated using Upper() Rob van Erk <erk.v@hotmail.com> - 2013-09-17 07:14 -0700

csiph-web