which way is the best to store data in vc++

which way is the best to store data in vc++

Post by Gottfried Che » Wed, 12 Jan 2000 04:00:00



for an online game i have to find out, which method is the fastest to save a
record to a table:
possibilites (as far as i know) are:
- generate the corresponding sql-string and send it to the server to execute
it
- open the corresponding ado-recordset object and set the values, then
update the recordset.
(the second is easier to programfor me, since generating an "update.."
string when i have a lot of data is quite a pain in c++.)

does anyone know any performance values concerning this problem?
thx
gottfried

 
 
 

which way is the best to store data in vc++

Post by Tony Rogerso » Wed, 12 Jan 2000 04:00:00


Id use a stored procedure and then pass the values as parameters to it -
nice and clean !

--
Tony Rogerson SQL Server MVP
Torver Computer Consultants Ltd
www.sql-server.co.uk (UK User group, code library, FAQ etc..)


Quote:> for an online game i have to find out, which method is the fastest to save
a
> record to a table:
> possibilites (as far as i know) are:
> - generate the corresponding sql-string and send it to the server to
execute
> it
> - open the corresponding ado-recordset object and set the values, then
> update the recordset.
> (the second is easier to programfor me, since generating an "update.."
> string when i have a lot of data is quite a pain in c++.)

> does anyone know any performance values concerning this problem?
> thx
> gottfried


 
 
 

1. Best ways to store Text of indeterminate length

I'm designing a conversation board application and considering the best way
to store the Body of the posts.  They are of indeterminate length.  I expect
to grab each post (at least the Body) one at a time.  I also plan to do text
searching of them.  What I see as the options are:

1 Store the Body as a Text type field in the same table as the rest of the
post (Simplest option)

2 Store the Body as a Text type field in a separate table (Do I get a speed
advantage when I am searching the rest of the post if the Text fields are
not in the Table?)

3 Chop the Body up into some arbitrary length (say 255 chars) chunks and
store them as  char or varchar in a separate table along with contective and
ordering data.  Then when I need them grab all the chunks and put them back
together. (One of the nice things about this is that I can get the first x
number of characters of the body cheaply for a preview)

The big concerns that have me looking at this so closely is that I get the
impression that dealing with Text columns is system expensive and it is
important that this app scales well.

Any wisdom or advice is appreciated

Matthew Nichols

Dream Team Technologies

2. HTML Tables in Vb5

3. Best ways of Debugging a Stored Proc...

4. SCo Unix Flavours

5. RFI - Best ways to sync data across platforms

6. VFP5 : parameters

7. newbie question

8. best database grid i can use in vc++

9. vc++ with jet... best solution

10. call stored procedure using ADO in vc++?

11. stored procs and vc++

12. call stored procedure using ADO in vc++?