Welcome, Guest ( Customer Panel | Login )




 All Forums
 VPCart Forum
 General help me questions
 Searching for a city
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Derivative
Starting Member

14 Posts

Posted - January 23 2019 :  20:04:36  Show Profile  Reply with Quote
What could be a solution to query and search for customers who are from city like Montreal and Montréal assuming we don''t know all the cities in the word with accents like é?

diegomilito
VP-CART Expert

Argentina
779 Posts

Posted - January 24 2019 :  20:08:30  Show Profile  Reply with Quote
you can try one thing using sql query from query&export menu

what i can suggest you do this sql query:

* from customers where city like ''%montr%''

im sure that will help but you can try first and tell me how you do

diego
Go to Top of Page

Derivative
Starting Member

14 Posts

Posted - January 24 2019 :  21:12:45  Show Profile  Reply with Quote
Thanks for your answer Diego. But what if we don''t know the name of the city that comes with accented char. Montreal/Montréal was an obvious one for me. For example, if I search for customer in Mexico, I''d lose all those who placed orders from México!!! The list wouldn''t be accurate. Any suggestions?

Edited by - Derivative on January 24 2019 21:13:43
Go to Top of Page

diegomilito
VP-CART Expert

Argentina
779 Posts

Posted - January 26 2019 :  02:58:25  Show Profile  Reply with Quote
well,, country value in customers table is stored by vpasp i think in abbreviation which is MX for mexico .. you just only need to use sql like [* from customers where country = ''MX'']


diego
Go to Top of Page

manilow
VP-CART New User

France
134 Posts

Posted - January 29 2019 :  15:09:31  Show Profile  Visit manilow's Homepage  Reply with Quote
Please try the following query:

S ELECT * FROM customers WHERE city COLLATE utf8_unicode_ci Like ''%montreal%'' COLLATE utf8_unicode_ci

This works for mysql but maybe slightly different for SQLserver.

Erik
aquathermia.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000
0 Item(s)
$0.00