Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Any ideas to index/speed this up?
Message
De
21/07/2003 16:15:04
 
 
À
21/07/2003 02:27:04
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Allemagne
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00810823
Message ID:
00812141
Vues:
15
Thanks so much Agnes for all your help, I finally got your code running and unfortunately it took just about as long as my seek, replace and delete system.

It gave me an idea though that I think might work. I'm thinking about selecting my rate tables into 13 rate tables based on the length of the rate code. Then do an inner join with the cdr on the 13 digit rates, replace them with the rate info. Next join with all the matches for 12 digit rate codes for empty(cdr.dest) , then the same for 11 digit rates, and so on.

I noticed with Dan's code that the set relation was almost instant, it was just not selecting the right matches.

Think this might be a quicker way?

If you don't understand, here's psuedocode for what I plan to do.
select rate
index on code tag code

select cdr
index on len(dnis)+dnis tag dnislength

for i=13 to 1 step -1
  SELECT * FROM rate WHERE len(ALLTRIM(code))=i INTO cursor rate+(i)
  set relation to rate+(i).code into cdr
  set skip to cdr
  replace rate table info for empty(cdr.dest) into cdr table
endfor
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform