Hi,
The question of READU vs READ when you are doing updates is moot. If you do a
READ then a WRITE, UniVerse/UniData will perform the record lock. The only
difference is with READ you are gambling that no one else is updating the
record before you perform your WRITE.
Performance, as others suggested, there are several things to do:
Tune your files.
If you are using dynamic files, make sure you have the MINIMUM.MODULUS set
to reduce the shrink and merging
If the records are "lumpy" redesign them so you have a header file and a
detail file, with detail files being individual records for the associated
values.
Use LIST.INDEX with the STATISTICS option to see if you have huge index
value, you may need to refine the index.
Check your hardware, you may have a bottleneck due to slow disk, I/O pipe.
Minimize the number of times you go through the associated values.
Use READU with the "LOCKED" clause, if the record is locked, add logic to
"queue" it up and try the records again once everything else is processed
(WRITEs will hang on a lock if you don't have the "LOCKED" clause, just like a
READU without the "LOCKED" clause.
Good luck!
Tom
RATEX Business Solutions
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Symeon Breen
Sent: Tuesday, May 01, 2012 4:44 AM
To: 'U2 Users List'
Subject: Re: [U2] READU vs READ
Have you been able to do any os level tools to see what the utilisation of
resources is. E.g. on linux, vmstat, top, iostat will show you if it is a
diskio or cpu bottleneck. If it is diskio (i.e. high wait on io times) then
you may need to upgrade the disks or add more ram so you have more data in
cache.
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Dave Laansma
Sent: 01 May 2012 02:58
To: U2 Users List
Subject: Re: [U2] READU vs READ
Oh ... you're good ... I ALMOST pasted it ...
I know better that to put even FICTITIOUS code on this board ... unless I'm
just trying to rile things up about the OS. |-)
I do appreciate all of the input. Thank y'all for the info. I'll see what I can
do.
Sincerely,
David Laansma
IT Manager
Hubbard Supply Co.
Direct: 810-342-7143
Office: 810-234-8681
Fax: 810-234-6142
www.hubbardsupply.com
"Delivering Products, Services and Innovative Solutions"
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Wjhonson
Sent: Monday, April 30, 2012 9:47 PM
To: [email protected]
Subject: Re: [U2] READU vs READ
why not post the relevant code you are using to do the field updates perhaps we
can see some inefficiency in the way you're grabbing and updating fields you
said the records were sizeable and that raises my eyebrow (just one)
-----Original Message-----
From: Dave Laansma <[email protected]>
To: U2 Users List <[email protected]>
Sent: Mon, Apr 30, 2012 6:38 pm
Subject: Re: [U2] READU vs READ
No indexes and no triggers.
Sincerely,
David Laansma
IT Manager
Hubbard Supply Co.
Direct: 810-342-7143
Office: 810-234-8681
Fax: 810-234-6142
www.hubbardsupply.com
"Delivering Products, Services and Innovative Solutions"
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Gregor Scott
Sent: Monday, April 30, 2012 9:22 PM
To: U2 Users List
Subject: Re: [U2] READU vs READ
Add to the mix indexes and triggers. They can both add to the time needed to
update just one record.
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Buss, Troy
(Contractor, Logitek Systems)
Sent: Tuesday, 1 May 2012 11:12 AM
To: U2 Users List
Subject: Re: [U2] READU vs READ
Inefficient file sizing and disk I/O are your possible issues with
slowness. You might be able to address the first at your desk, the
latter may require a purchase order. How old is your hardware?
We recently upgraded to a virtual server and just using more current technology
hard drives we doubled all of our disk I/O from what we had 5 or
6 years ago. CPU speed increased as well, but that was not as suprising.
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Dave Laansma
Sent: Monday, April 30, 2012 6:01 PM
To: U2 Users List
Subject: Re: [U2] READU vs READ
Yes, using SELECT and READNEXT. These are sizable records. The logic is very
straight forward, just updating several multi-valued fields in each record
(month end).
500,000 have been updated and I'm 2:45:00 into the process.
________________________________________________________________________
_____
Scanned by IBM Email Security Management Services powered by MessageLabs.
For more information please visit http://www.ers.ibm.com
This email is intended only for the use of the party to which it is addressed
and may contain information that is privileged, confidential, or protected by
law. If you are not the intended recipient you are hereby notified that any
dissemination, copying or distribution of the email or its contents is strictly
prohibited. If you have received this message in error, please notify us
immediately, by replying to the message and deleting it from your computer.
WARNING: Internet communications are not assured to be secure or clear of
inaccuracies as information could be intercepted, corrupted, lost, destroyed,
arrive late or incomplete, or contain viruses. Therefore, we do not accept
responsibility for any errors or omissions that are present in this email, or
any attachment, that have arisen as a result of e-mail transmission.
________________________________________________________________________
_____
_______________________________________________
U2-Users mailing list
[email protected]
http://listserver.u2ug.org/mailman/listinfo/u2-users
--
Message protected by DealerGuard: e-mail anti-virus, anti-spam and content
filtering.
http://www.pentanasolutions.com
Click here to report this message as spam:
https://login.mailguard.com.au/report/1EE0zigg55/70gcZxRJUITQXy3UHcVFYT/
0.002
This email and any attachments to it are confidential.
You must not use, disclose or act on the email if you are not the intended
recipient. Liability limited by a scheme approved under Professional Standards
Legislation.
_______________________________________________
U2-Users mailing list
[email protected]
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
[email protected]
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
[email protected]
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
[email protected]
http://listserver.u2ug.org/mailman/listinfo/u2-users
-----
No virus found in this message.
Checked by AVG - www.avg.com
Version: 10.0.1424 / Virus Database: 2411/4969 - Release Date: 04/30/12
_______________________________________________
U2-Users mailing list
[email protected]
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
[email protected]
http://listserver.u2ug.org/mailman/listinfo/u2-users