rethinking our POS -> website

Results 1 to 3 of 3

Thread: rethinking our POS -> website

  1. #1
    Join Date
    Dec 1969

    Default rethinking our POS -> website

    What we are currently doing is this: the client outputs a file from his legacy POS system ("&#124" delemited, aprox. 7000 lines/records)<BR>he uploads the file to our server and then runs a "parse" on it (asp page in his admin menu).<BR>The problem is this, the script that does the parsing is VERY slow (aprox 5 minutes while the processor is pined)<BR>one of the problems is that we are using Access, I know this. but I would like to make the script MUCH more efficent. Here is an overveiw of how it works<BR><BR>delete contents of inv table<BR>Open inv file<BR>loop<BR> get next line/record<BR> split line<BR> iterate through columns adding values from split line<BR> alter sister table if need be.<BR> commit record<BR>loop<BR><BR>some changes I thought I could make are - convert the inv file to XML and let the OLEDB engine handle it<BR><BR>disconnect recordset and try and only commit records that have changed.<BR><BR>any other thoughts on how to speed this up?

  2. #2
    Join Date
    Dec 1969

    Default suggestions only...

    1. DO NOT CREATE A RECORDSET<BR>2. use insert sql to add records<BR>example:<BR>sql1 = "insert into table1(fields) values ( concatenate values<BR>watch quotes around strings<BR>&#039;then<BR>connection1.execute sql1<BR>&#039;will add record, and very fast as well<BR><BR>3. to determine if u need to update any related table, use sql query then update related table or not<BR><BR>for example to determine if table 2 has a table 1 related record<BR>sql1 = "select count(*) as count1 from parenttable,childtable<BR>where ="<BR>&#039;create rs to find out count1<BR>&#039;no problem here with rs , since it will have one value only<BR>&#039;of rs("count1") = 0 then there are no related records , u may want to update childtable<BR>&#039;again use insert<BR><BR>3. a com obj of the above asp file, will run real real fast.<BR><BR>that will speed up things<BR>

  3. #3
    Steve Cimino Guest

    Default Additionally

    Instead of using DELETE contents, use this -- MUCH faster.<BR><BR>TRUNCATE TABLE<BR>tablename<BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts