>>this.oCa = createobject([CursorAdapter]) >> >>text TO this.oCa.SelectCmd PRETEXT 15 NOSHOW >> SELECT test_financing.keyID, Test_financing.tip_id, Test_financing.amount, >> Test_financing.source, Test_financing._year >> FROM \\tpdfiles\data\dfreeman\tip\data\TEST_FINANCING.DBF >> WHERE Test_financing._year = ( ?m.lnYear ) >> ORDER BY Test_financing.tip_id >>endtext >> >>this.oCa.allowinsert = .t. >>this.oCa.insertcmd = "" >>this.oCa.buffermodeoverride = 3 && 3 = row buffering, 5 = table buffering >>this.oCa.datasourcetype = [NATIVE] && native fox datasource >>this.oCa.sendupdates = .t. && unnecessary except with ODBC or ADO >>this.oCa.wheretype = 1 && >>this.oCa.tables = [test_financing] && >>this.oCa.fetchsize = -1 && primarily for remote views >>this.oCa.keyfieldlist = [keyid] && the primary key for the table >>this.oCa.updatenamelist = "keyid test_financing.keyid," + ; >> "tip_id test_financing.tip_id," + ; >> "amount test_financing.Amount," + ; >> "source test_financing.Source," + ; >> "_year test_financing._year" >> >>this.oCa.updatablefieldlist = "keyid, tip_id, amount, source, _year " >>this.oCa.alias = this.sourcetable >> >>m.lnYear = this._year >>this.oCa.cursorfill() >>>>Thanks
>TEXT TO this.oCa.SelectCmd PRETEXT 15 NOSHOW > SELECT test_financing.keyID, > Test_financing.tip_id, > Test_financing.amount, > Test_financing.source, > Test_financing._year, > TEST_PHASES.Phase > FROM TEST_FINANCING > [LEFT | INNER] JOIN TEST_PHASES ON TEST_FINANCING.Tip_Id = TEST_PHASES.Tip_Id AND > TEST_FINANCING._year = TEST_PHASES._year > WHERE Test_financing._year = ( ?m.lnYear ) > ORDER BY Test_financing.tip_id >ENDTEXT >Thanks Borislav. There must be something more cause I'm not getting a result cursor. Here is my code.
text TO this.oCa.SelectCmd PRETEXT 15 NOSHOW SELECT test_financing.keyID, Test_financing.tip_id, Test_financing.amount, Test_financing.source, Test_financing._year, test_phases.phase FROM \\tpdfiles\data\dfreeman\tip\data\TEST_FINANCING.DBF left join test_phases on test_financing.tip_id = test_phases.tip_id WHERE Test_financing._year = ( ?m.lnYear ) ORDER BY Test_financing.tip_id endtext