[VSDK Macho/PB] 1.9.6

Ruslan Zasukhin sunshine at public.kherson.ua
Tue Jan 28 19:39:12 CST 2003


on 1/28/03 3:52 PM, Totte Alm at totte at code66.se wrote:

> Hello Ruslan,
> 
> I'm having a bit of a trouble with cursor->Update()
> 
> This SQL to generate the Cursor:
> 
> mc = master->SqlSelect(    "SELECT H.recid, H.IsInGovBook, H.totalshares,
> H.totalvotes, H.isbuyback, "
> "S.shareindex, S.shares, I.votevalue FROM HolderTable H, ShareRecord S,
> "
> "ShareInfoTable I WHERE (H.IsGoverner=0 AND H.isbundlerecord=0) AND ("
> "(S.parentHolder = H.recid) AND (I.shareindex = S.shareindex) AND "
> "(I.isvisible=1)) GROUP BY H.recid, S.shareindex");
> 
> As this is a multicolumn cursor, readonly is set. Is the ANY way I can
> update records for this cursor without having to do
> db->table->GoToRecord(xx) and set the values manually? This really
> hurts performance as the BO is pretty large.

Hi Totte,

At least now no way.

In future it is possible make cursors on few tables to be WRITE,
If joined tables are 1 : 1.

Or may be also for fields of M table this is possible.

Problem with performance is that you need do BaseObject.goto( recID )
And this load all fields of this BaseObject, but you want update only one
field ?

Totte, in fact cursor.Update() will do the same -- make full record to be
current. This is needed in case you update a field which also is used in
some BaseObject. So to correctly update this method, it needs set correct
values for other fields also.

Probably here possible some optimizations in kernel, but they looks to be
very hard.

-- 
Best regards,
Ruslan Zasukhin      [ I feel the need...the need for speed ]
-------------------------------------------------------------
e-mail: ruslan at paradigmasoft.com
web: http://www.paradigmasoft.com

To subscribe to the Valentina mail list go to:
http://listserv.macserve.net/mailman/listinfo/valentina
-------------------------------------------------------------



More information about the Valentina mailing list