|
-
Jun 1st, 2001, 03:50 PM
#1
Thread Starter
New Member
VB Performance
Hi
I have a .exe written in Visual Basic 6 which reads from an Oracle Database and writes one row to an
Excel worksheet using an application ref object (Note: I'm a java developer farly new to VB!). Most
calculations are performed internally (i.e. not within the Excel worksheet) and the problem is:
On Workstation 4 256Mb RAM, 16Gb disc space, 233 Mhz
: it takes on average 1 min to complete this operation.
On Server4 512MbRAM, 16Gb disc space, 700 Mhz (Dual Processor)
: it takes on average 3-4 min to complete this operation.
Why the discrepancy ?
Any thoughts ?
Regards
Hugh O'Donnell
Software Engineer
Ingenco
Regards,
Hugh O'Donnell
Lead Software Engineer
Ingenco
-
Jun 3rd, 2001, 02:11 AM
#2
Hyperactive Member
Hmmm...
Some thoughts:
*Maybe the server is busy doing other things.
*Where is the database stored?
I read something once about awful byval or byref performace on the server or maybe it was early or late binding I can;t remember, but i;ll check it out if you want.
There are 10 types of people in the world - those that understand binary, and those that don't.
-
Jun 3rd, 2001, 10:46 AM
#3
Thread Starter
New Member
David
Many thanks for your reply!
The Oracle Database is on the same machine...The only other services running are IIS & the Servlet engine JRun.
I would appreciate you chasing up for me, and I will look into the ByRef/ByVal - thanks!
Regards,
Hugh
Regards,
Hugh O'Donnell
Lead Software Engineer
Ingenco
-
Jun 4th, 2001, 11:39 PM
#4
Hyperactive Member
here it is...
Two possibilities. This is according to VB and VBA In A Nutshell by O'Reilly.
1)Early or late binding. This is used when you declare objects. Dim x as new y is early bound. dim x as y and then set x=y is also early bound. but dim x as object is late bound. Now check this: everyone always says use early binding at all costs. This is true for out-of-process EXEs such as running an exe across the network. But untrue for inprocess stuff such as you may be using on your server.
Also, the differences between early and late are more apparent on Win9x than NT.
2)Passing variables to procedures is faster with ByRef with in-process. Byval has the performance advantage when out-of-process.
Helps?
There are 10 types of people in the world - those that understand binary, and those that don't.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|