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
itimesAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

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

0
itimesAuthor Commented:
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"
0
mcmonapCommented:
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
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

Duane LawrenceCommented:
So the program runs fine after a restart.  That just screams memory leak to me.

SQL Server 7 was bad about that until service pack 3, run
select @@version
check against the website below:
http://www.sqlteam.com/item.asp?ItemID=8318

Also check your VB app for memory leaks.  You can do it manually or buy a product that will do it for you.  I never wrote VB, so I can't recomend a product that will do that for VB.  (I did write C, C++, C# for year and know good ones for that)

Duane
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
wael_tahonCommented:
I agree with duanelawrence  point, I think it is a memory leak
0
LowfatspreadCommented:
....
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....


     
0
itimesAuthor Commented:
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 !!!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.