Link to home
Start Free TrialLog in
Avatar of itimes
itimes

asked on

Memory allocation failure

Hi

Im running a VB program that updates my SQLserver 7 DB via an odbc connection.

I had a "Memory allocation failure" error on an update that I though was very simple see below

ccount = 1
refid = 018595

update TBL1 set fileCount = '" & ccount & "' where refid = '" & refid & "'

As I understand an update it will only updates the "SET" column and will only modify that element yet I got the Memory allocation failure error ???

is this right what iv been told that an update does not pull out the complete record contents when a set column is defined, it only modifies the column named in the SET ??? yes ???

What could cause this error ??
IT
Avatar of wael_tahon
wael_tahon
Flag of Egypt image

if you run your transaction in query analyzer what you get ?

Avatar of itimes
itimes

ASKER

wael_tahon,

I haven trun this is query analyzer but i hace run my prgrams isnce after a machine restarts and its working fine ... ?!?!?!

Is this correct what iv been told though ???

"that an update does not pull out the complete record contents when a set column is defined, it only modifies the column named in the SET"
Hi itimes,

Yes that is correct, the update statement you have would only make a change to the fileCount column where the refid is equal to what you have specified
ASKER CERTIFIED SOLUTION
Avatar of Duane Lawrence
Duane Lawrence
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I agree with duanelawrence  point, I think it is a memory leak
....
for info.
  the update only affects the namend column
  whatever data the dbms have to use to identify that column depends on the indexes / access strategy it
   needs to use to navigate to those rows...
  dependant on the column type and indexes upon whihc the updated column resides additional work maybe required
   to move data rows within the affected pages/ split / join pages depending on the increase/decrease in particular
   row data sizes, that could get more complicated if a text or image column is in the row and the store data within the page option is also specified....


     
Avatar of itimes

ASKER

Thank you for all teh info about the UPDATE statement ... My SQL was simple and it turned out to be a memory (memory leak) problem ... rebuilt software onto 2000 instaed of 98 and has run for teh last 7 days straight with no problems !!!