This works .. if sql statement recordset returns no rows ..
IF oRS1:eof
Msginfo( "not found" )
RETURN(NIL)
ENDIF
This works .. if sql statement recordset returns no rows ..
IF oRS1:eof
Msginfo( "not found" )
RETURN(NIL)
ENDIF
Rick Lipkin wrote:Why when I try to open a recordset and the sql statement does not find any results .. can I not try to trap a 'no find' situation ..
IF oRs:EOF
// no records
ENDIFIF oRs:RecordCount = 0
// no records
ENDIFRick Lipkin wrote:Looking for that magic INSERT sql statement and the connection string to update all the matching relational records and tables.
Enrico
I think I came to that same conclusion .. many relational tables .. just apply insert updates to each instead of combining them all into one join ..
I can tell you .. this exersize has been a valuable lesson .. but thinking down the road .. I was toying with the idea of sqlrdd for a Ms Sql project coming up ..
Any feelings on ADO vs ( perhaps ) the sqlrdd ?? ... what has to be on the client to make the connection ?? .. for ms sql that is ?? I am very pleased with ADO speed and recordsets..
Thanks
Rick Lipkin
Rick Lipkin wrote:Any feelings on ADO vs ( perhaps ) the sqlrdd ?? ... what has to be on the client to make the connection ?? .. for ms sql that is ??
Harbour's USRRDD could be used to easily implement an ADORDD and test how it goes ![]()
True. The problem with USRRDD is the lack of documentation and samples.
EMG
Enrico
One last ( I hope ) question .. I am using your :filter suggestion for locate records .. is there a :find() or :locate() method in ADO .. I just want to 'seek' a record in a recordset and move the pointer to that record ..
Also .. it appears that a recordset is ( like ) a 'local cursor' .. what are the visability of updates from one workstation recordset to another workstation ( recordset ) that may have the same table open .. does the UPDATE clause on the listbox allow the recordsets to be refreshed from the table .. or is it once the recorset is created .. it never goes back to the origional table for refreshes ??
Thanks again .. I will be converting a large dbfcdx app soon to ms sql .. I know if I go the ADO route i will have to re-write a good bit of code .. but a 'wrapper' ADO rdd would be nice...
Rick Lipkin
Rick Lipkin wrote:I am using your :filter suggestion for locate records .. is there a :find() or :locate() method in ADO .. I just want to 'seek' a record in a recordset and move the pointer to that record ..
oRs:Find( "Cliente LIKE 'A%'" )Rick Lipkin wrote:Also .. it appears that a recordset is ( like ) a 'local cursor' .. what are the visability of updates from one workstation recordset to another workstation ( recordset ) that may have the same table open .. does the UPDATE clause on the listbox allow the recordsets to be refreshed from the table .. or is it once the recorset is created .. it never goes back to the origional table for refreshes ??
Enrico
Thank you VERY much .. I think you have the right open parameters set 1,3 .. from what I can tell .. visibility for edits are there and adopenkeyset supports the absolute position for records and top and bottom... where adopendynamic does not ..
I did see a :resync method .. going to have to set up a share on my home network here to test ..
I do find Antonio's comment interesting on ado wrappers intergrated into an RDD .. my only concern ( moving into a ms sql world soon ) .. what ado engine would have to be loaded on the workstation clients for MS Sql ?? .. I don't think MS office loads an ADO client for that particular connection ??
Rick Lipkin
"Provider=sqloledb;Data Source=ipaddress;User Id=userid;Password=password"