> UpdateNameList = ; > [cust_id_a testdata!customer.cust_id, company testdata!customer.company, contact ; > testdata!customer.contact, title testdata!customer.title, address ; > testdata!customer.address, city testdata!customer.city, region ] ; > +[testdata!customer.region, postalcode_a testdata!customer.postalcode, country ; > testdata!customer.country, phone testdata!customer.phone, fax ; > testdata!customer.fax, maxordamt testdata!customer.maxordamt, order_id ] ; > +[testdata!orders.order_id, cust_id_b testdata!orders.cust_id, emp_id ; > testdata!orders.emp_id, to_name testdata!orders.to_name, to_address ; > testdata!orders.to_address, to_city testdata!orders.to_city, to_region ]; > +[testdata!orders.to_region, postalcode_b testdata!orders.postalcode, to_country ; > testdata!orders.to_country, ship_count testdata!orders.ship_count, ship_via ; > testdata!orders.ship_via, order_date testdata!orders.order_date, order_amt ] ; > +[testdata!orders.order_amt, order_dsc testdata!orders.order_dsc, order_net ; > testdata!orders.order_net, require_by testdata!orders.require_by, shipped_on ; > testdata!orders.shipped_on, freight testdata!orders.freight] >>
>>local loCursor as CursorAdapter >> >>open database ("C:\PROGRAM FILES\MICROSOFT VISUAL FOXPRO 8\SAMPLES\DATA\TESTDATA.DBC") >> >>loCursor = createobject('TESTView') >> >>with loCursor >> if .CursorFill() >> browse >> tableupdate(1) >> endif .CursorFill() >>endwith >> >>close databases all >> >>DEFINE CLASS TESTVIEW AS CursorAdapter >> Alias = [testview] >> DataSourceType = [Native] >> SelectCmd = ; >> [SELECT Customer.cust_id, Customer.company, Customer.contact, Customer.title, ; >> Customer.address, Customer.city, Customer.region, Customer.postalcode, ; >> Customer.country, Customer.phone, Customer.fax, Customer.maxordamt, ; >> Orders.order_id, Orders.cust_id, Orders.emp_id, Orders.to_name, ; >> Orders.to_address, Orders.to_city, Orders.to_region, Orders.postalcode, ; >> Orders.to_country, Orders.ship_count, Orders.ship_via, Orders.order_date, ; >> Orders.order_amt, Orders.order_dsc, Orders.order_net, Orders.require_by, ; >> Orders.shipped_on, Orders.freight FROM testdata!customer INNER JOIN ; >> testdata!orders ON Customer.cust_id = Orders.cust_id] >> Tables = ; >> [testdata!customer, testdata!orders] >> KeyFieldList = ; >> [cust_id_a, order_id] >> UpdatableFieldList = ; >> [company, contact, title, address, city, region, postalcode_a, country, phone, ; >> fax, maxordamt, cust_id_b, emp_id, to_name, to_address, to_city, to_region, ; >> postalcode_b, to_country, ship_count, ship_via, order_date, order_amt, ; >> order_dsc, order_net, require_by, shipped_on, freight] >> UpdateNameList = ; >> [cust_id_a testdata!customer.cust_id, company testdata!customer.company, contact ; >> testdata!customer.contact, title testdata!customer.title, address ; >> testdata!customer.address, city testdata!customer.city, region ; >> testdata!customer.region, postalcode_a testdata!customer.postalcode, country ; >> testdata!customer.country, phone testdata!customer.phone, fax ; >> testdata!customer.fax, maxordamt testdata!customer.maxordamt, order_id ; >> testdata!orders.order_id, cust_id_b testdata!orders.cust_id, emp_id ; >> testdata!orders.emp_id, to_name testdata!orders.to_name, to_address ; >> testdata!orders.to_address, to_city testdata!orders.to_city, to_region ; >> testdata!orders.to_region, postalcode_b testdata!orders.postalcode, to_country ; >> testdata!orders.to_country, ship_count testdata!orders.ship_count, ship_via ; >> testdata!orders.ship_via, order_date testdata!orders.order_date, order_amt ; >> testdata!orders.order_amt, order_dsc testdata!orders.order_dsc, order_net ; >> testdata!orders.order_net, require_by testdata!orders.require_by, shipped_on ; >> testdata!orders.shipped_on, freight testdata!orders.freight] >> SendUpdates = .F. >> CompareMemo = .T. >> FetchAsNeeded = .F. >> FetchMemo = .T. >> FetchSize = 100 >> MaxRecords = -1 >> Prepared = .F. >> UpdateType = 1 >> UseMemoSize = 255 >> WhereType = 3 >>ENDDEFINE >>