ADO RDD xHarbour

Re: ADO RDD xHarbour

Postby AHF » Fri Mar 20, 2015 3:46 pm

Antonio,

What func calls the ADO_ORDDESTROY ?
Regards
Antonio H Ferreira
AHF
 
Posts: 838
Joined: Fri Feb 10, 2006 12:14 pm

Re: ADO RDD xHarbour

Postby Antonio Linares » Fri Mar 20, 2015 4:18 pm

Antonio,

Place an error in ADO_ORDDESTROY() and you will see the calls stack list

in example, write:
x++

it will error and you will see what function calls it
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41462
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: ADO RDD xHarbour

Postby AHF » Fri Mar 20, 2015 6:44 pm

Antonio,

Where is information about the controling index in ADO RDD ?
Regards
Antonio H Ferreira
AHF
 
Posts: 838
Joined: Fri Feb 10, 2006 12:14 pm

Re: ADO RDD xHarbour

Postby Antonio Linares » Fri Mar 20, 2015 9:39 pm

The controlling index is set in the ADO recordset:

oRecordSet:Index := aOrderInfo[ UR_ORI_BAG ]
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41462
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: ADO RDD xHarbour

Postby AHF » Sat Mar 21, 2015 12:47 pm

Antonio,

I needed an VAR to save the controling index.
All indexes are "virtual" they really dont exist as files in ADORDD.
The indexes are SELECTs
Its solved. :D

Now I need to know RDD function to DBRLOCKLIST()

What is aLockInfo[ UR_LI_METHOD ] := DBLM_MULTIPLE ?
Regards
Antonio H Ferreira
AHF
 
Posts: 838
Joined: Fri Feb 10, 2006 12:14 pm

Re: ADO RDD xHarbour

Postby Antonio Linares » Sat Mar 21, 2015 9:20 pm

Antonio,

Very good, you are progressing :-)

have a look at this:
http://www.ousob.com/ng/53tecref/ng42f2a.php
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41462
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: ADO RDD xHarbour

Postby AHF » Sat Mar 21, 2015 10:45 pm

Antonio,

Ok got it!

How can I have DBRLOCKLIST() to work?
Regards
Antonio H Ferreira
AHF
 
Posts: 838
Joined: Fri Feb 10, 2006 12:14 pm

Re: ADO RDD xHarbour

Postby Antonio Linares » Sun Mar 22, 2015 7:13 am

Antonio,

See how it is implemented in Harbour:

Code: Select all  Expand view
HB_FUNC( DBRLOCKLIST )
{
   AREAP pArea = ( AREAP ) hb_rddGetCurrentWorkAreaPointer();

   if( pArea )
   {
      PHB_ITEM pList = hb_itemArrayNew( 0 );
      SELF_INFO( pArea, DBI_GETLOCKARRAY, pList );
      hb_itemReturnRelease( pList );
   }
   else
      hb_errRT_DBCMD( EG_NOTABLE, EDBCMD_NOTABLE, NULL, HB_ERR_FUNCNAME );

}
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41462
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: ADO RDD xHarbour

Postby AHF » Sun Mar 22, 2015 7:55 am

Antonio,

Sorry didnt catch it.

I'm not familiar with harbour C ext.

Where can I keep the locklist array updated in adordd everytime ADO_LOCK and ADO_UNLOCK are called?

Locks dont really exist in the files its only for record position information.
Regards
Antonio H Ferreira
AHF
 
Posts: 838
Joined: Fri Feb 10, 2006 12:14 pm

Re: ADO RDD xHarbour

Postby Antonio Linares » Sun Mar 22, 2015 8:12 am

Antonio,

In that C code an array is created and filled with an array (DBI_GETLOCKARRAY)

The question here is: Does it have sense to talk about this in ADO ? Do we just return an empty array ?

Are we going to need those locks positions ? I guess no
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41462
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: ADO RDD xHarbour

Postby AHF » Sun Mar 22, 2015 8:34 am

Antonio,

Its absolutly necessary to keep the locklist array.

In transactions we lock and append all necessary records and then we loop trough the locklist with dbgoto to make all replaces. If a lock fails the transaction fails.

Altough with ADO never fails as real locks dont matter we still need to have it filled with bookmarks to return to each record later.
Regards
Antonio H Ferreira
AHF
 
Posts: 838
Joined: Fri Feb 10, 2006 12:14 pm

Re: ADO RDD xHarbour

Postby Antonio Linares » Sun Mar 22, 2015 8:47 am

Antonio,

ok, you can save them using bookmarks, yes
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41462
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: ADO RDD xHarbour

Postby AHF » Sun Mar 22, 2015 8:53 am

Antonio,

I need your support here because I still dont know how to do it.
Regards
Antonio H Ferreira
AHF
 
Posts: 838
Joined: Fri Feb 10, 2006 12:14 pm

Re: ADO RDD xHarbour

Postby Antonio Linares » Sun Mar 22, 2015 9:19 am

Antonio,

Please post your most recent adordd.prg file and I review it, thanks
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41462
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: ADO RDD xHarbour

Postby AHF » Sun Mar 22, 2015 9:40 am

Antonio,

Sent to your email.
Regards
Antonio H Ferreira
AHF
 
Posts: 838
Joined: Fri Feb 10, 2006 12:14 pm

PreviousNext

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 145 guests