-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Le 25/06/14 01:20, Cédric Krier a écrit : > On 17 Jun 01:24, Cédric Krier wrote: >> Hi, >> >> I started an POC [1] to add autocompletion of zip code and city on >> addresses. It just adds a Model to store the couple zip-code per country >> (and optionally per subdivision). >> I also plan to write a proteus script to load such couples from >> http://www.geonames.org/ >> >> [1] https://bugs.tryton.org/issue4004 > > The script has been added. I tested with some countries so be sure yours > are working. > As far as I see there were only talk about naming which is out of the > scope. > This is quite cool... needs proteus to install . I tried importing 'FR' since over an hour now, it's still running.. (pgadmin3 shows country_zip at just over 26K at the moment ) Notice the following in the postgres logs: > LOG: connexion reçue : hôte=::1 port=54129 > LOG: connexion autorisée : utilisateur=tryton, base de données=trytest > LOG: déconnexion : durée de la session : 0:00:00.212 > utilisateur=tryton base=trytest hôte=::1 port=47725 > LOG: connexion reçue : hôte=::1 port=32949 > LOG: connexion autorisée : utilisateur=tryton, base de données=trytest > LOG: déconnexion : durée de la session : 0:00:00.218 > utilisateur=tryton base=trytest hôte=::1 port=54129 > LOG: connexion reçue : hôte=::1 port=61172 > LOG: connexion autorisée : utilisateur=tryton, base de données=trytest > LOG: déconnexion : durée de la session : 0:00:00.136 > utilisateur=tryton base=trytest hôte=::1 port=32949 > LOG: connexion reçue : hôte=::1 port=34565 > LOG: connexion autorisée : utilisateur=tryton, base de données=trytest > LOG: déconnexion : durée de la session : 0:00:00.142 > utilisateur=tryton base=trytest hôte=::1 port=61172 > LOG: connexion reçue : hôte=::1 port=36351 > LOG: connexion autorisée : utilisateur=tryton, base de données=trytest > LOG: déconnexion : durée de la session : 0:00:00.149 > utilisateur=tryton base=trytest hôte=::1 port=34565 > LOG: connexion reçue : hôte=::1 port=53505 > LOG: connexion autorisée : utilisateur=tryton, base de données=trytest > LOG: déconnexion : durée de la session : 0:00:00.131 > utilisateur=tryton base=trytest hôte=::1 port=36351 It seems that each record is a new connection (database open/update/close)? FR has over 51K records. I know this is a one-time per db operation, but imagine multiple databases, and multiple countries.... I wonder if it would be quicker to do something like convert to trytond csv format and do a single transaction bulk load? -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBAgAGBQJUgtaJAAoJECAB22fHtp27uBkH/2EboDId2IQvIdYqE/fWg+GN GMyTUWjPbfpdCW9FFaFp3ZsXRt7JUb4imnvnH1cAWt0GOiAO7/FvXwnC8ZrpdjEC tg6791T7xhbeXl1HcghGy3RZ1+f/KHXsWsC2iHbcwQ+N8tZyQzcDZFOLnq66fTle T27VqUewZe9N6uiplhnFNbRMbDRkdoNMD+VgJI/6DwUqf6o0A1hhMK9Cmc2p/x07 wkOUlSdjKnO4j9NDRs2OE0sY7RyMwCgF0gNB8sPRABtpzI9n+zvBg+XJpbUICRdY B4N5kjHvHrTP8a1gV965mq5le1Hag3Yj+0f0GyKz7wtuedgVFQpbCv+Ig0RWzBs= =ZSmw -----END PGP SIGNATURE-----
