Updating access data from foxpro

I'd be interested to see if the tableupdate() approach is even faster then repeated sqlexec of a prepared statement. T.,"cur Append") is inserting all new records in batches, which you can define with CURSORSETPROP() of the 'Batch Update Count' setting.

The help file only talks about update performance, but that includes insert operations, too.

The default is 1 only, so set this up, also raise the Packet Size via SQLSet Prop(), the default only is 4KB.

If the IP paket loss rate is low in your LAN, try larger packets. of inserts to do, you might want to try using BULK INSERT (via SQL Pass-thru) into the SQL Server table.

This is generally faster than doing the way we have discussed - but how much faster depends on which back-end you are using.

Mike __________________________________ Mike Lewis (Edinburgh, Scotland) Visual Fox Pro articles, tips and downloads Mikes last advice you can use DBF data in Crystal Reports without first putting it into SQL Server, is most important. The reason I'm trying to put the data into SQL is that if I run the Crystal Report on the dbf file, the report keeps its "hooks" in the database file.

I have tried this: Select C5.*, bmsl.findno, bmsl.scrpad; FROM C5 Left Join bmsl On C5C5.partno C5.sorev = bmsl.itemparent bmsl.itemchild bmsl.rev; INTO Cursor C6 connstr = SQLSTRINGCONNECT("Driver=; Server=KOKATAT-507BB64\SQLExpress; Database=Web Portal; Trusted Connection=Yes") execmd = "INSERT INTO itemprojimstock (Item) VALUES (? SQLEXEC(connstr, execmd) SQLDISCONNECT(connstr) CLOSE ALL Chris, You're making several mistakes here. Whatever value you want to place in the table, you should copy that value to the variable named test.

So I came up with this code: Select C5.*, bmsl.findno, bmsl.scrpad; FROM C5 Left Join bmsl On C5C5.partno C5.sorev = bmsl.itemparent bmsl.itemchild bmsl.rev; INTO Cursor C6 SELECT C6 SCAN lc Item = C6. That won't make any difference to the result, but it will run quite a bit faster. Sorev)" SQLEXEC(connstr, lc Exe Cmd) ENDSCAN SQLDISCONNECT(connstr) CLOSE ALL Now I will have to figure out which way I should proceed from here.

Apart from those points, your code is looking much better. Sorev lc Exe Cmd= "INSERT INTO itemprojimstock (Item, Sono, Sorev) VALUES (? This exe gets run every time a Crystal Report is launched since it creates the table that the report pulls its data from.

From what I googled Crystal Reports 2008 is also still 32bit software.

so it could work, but also in prospect of the future storing data into SQL Server is a good choice.

Leave a Reply