How to Import Data into My Database?

Organizing my database - March 6, 2015

The My database module allows you to run your own database. You can define as many data categories as you need with as many data fields as you want. More info: read How to create data categories and data fields?

 

Step 1: creating data categories and data fields

Read How to create data categories and data fields? to create data categories and data fields required for your map.

In the previous article, we created the following data categories and data fields:

  • Opening Hours: opening times for each store
  • Amenities: services for each store like free wifi, mobile payment, 24-Hour service, drive-thru.

 

Step 2: creating a marker template with data fields

1. In the main menu, choose Options > Templates Collection

2. Click on the Add button to open New Template window.

3. Enter the following information:

  • Template name: the name of your marker template, for example StoreLocator.
  • Check the box Display markers address to display or hide the address for the visitors.
  • Click on Change icon of markers to choose for example the icon 55 of Google Earth 1 collection.

4. Click on Additional Properties and enter the following information:

Check the box Web link of markers and type the link properties:

  • URL Address: enter a web address, for instance: 'http://click2map.com/'
  • Text: enter the hypertext link you need to use like: 'Visit our website!'.

Check the box Email Link of markers and type the link properties:

  • Email: contact@click2map.com or the email address you need to publish.
  • Text: “Contact us” or other text you want to use as a hypertext link for the email address.
  • Tags: keywords separated with commas.

5. Click on Extra Tabs tab.

6. Click on Text button to add a tab with text and enter the following information:

  • Title: “Amenities”

Content:

  • Free Wifi: #Amenities.FreeWifi
  • Drive-Thru: #Amenities.Drive-Thru
  • 24-Hour service: #Amenities.24-HourService
  • Mobile payment: #Amenities.MobilePayment

7. You can create another Text tab for the second data category:

  • Title: "OpeningHours"

Content:

  • Monday: #OpeningHours.Monday
  • Tuesday: #OpeningHours.Tuesday
  • Wednesday: #OpeningHours.Wednesday
  • Thursday: #OpeningHours.Thursday
  • Friday: #OpeningHours.Friday
  • Saturday: #OpeningHours.Saturday
  • Sunday: #OpeningHours.Sunday

8. Click on Ok to save your template.

Each data field is in fact a variable composed of the name of the data category it belongs to and the name of the data field itself, separated by a dot. Custom variables always start with a # sign when internal Click2Map variables start with a $ sign (see: Click2Map Variables). Variables can be used in almost all text fields and Html areas of markers and marker templates.

Important: When using variables, the name of data categories and data fields must be entered exactly how they were written when you created them. Data categories, data fields and the corresponding variable names are case sensitive.

 

Step 3: preparing the import file

Import Click2Map function allows you to import markers (Read How to import venues from an Excel or CSV file). It's possible to import venues of your database and associate a template to each marker.

In our example, we prepare an import CSV file which will contain the following columns:

Main Information:

  • Store Reference
  • Address
  • Title

Additional data (My Database): these information match data fields defined during the first step. They are named in the import file by the name of the data category and the data field name, separated with a comma:

  • Amenities.FreeWifi
  • Amenitiess.Drive-Thru
  • Amenities.24-HourService
  • Amenities.MobilePayment
  • OpeningHours.Monday
  • OpeningHours.Tuesday
  • OpeningHours.Wednesday
  • OpeningHours.Thursday
  • OpeningHours.Friday
  • OpeningHours.Saturday
  • OpeningHours.Sunday

Marker Template Designation:

  • Template

Our import file thus contains 15 columns: the first line of the CSV file must contain the name of each column while the subsequent lines contain the actual data corresponding to each marker.

For easier editing of the import file, you can prepare it with a spreadsheet application such as MS Excel, OpenOffice or Google SpreadSheet. When you're done editing your data, simply save a copy of the file in CSV format (remember which separator you select).

 

Step 4: creating a map, import markers and publishing the map

1. To create a new map, click on Add > Map and enter the following information:

  • Title (title visible on the the generated map)
  • Nom ou ID (internal Click2Map ID) : il est préférable de laisser la valeur par défaut
  • Map Center Address: type the country, the area onle pays, la ville ou la région sur laquelle vous souhaitez que votre carte soit centrée

2. Click on the Geocode button to center the map on the area of your choice.

3. Adjust the zoom level using the Zoom Level horizontal slider.

4. Use the Tools > Import command from Click2Map's main menu and follow the instructions provided by the import wizard.

-Choose the CSV format of your file

-In the Choose columns associations window, add the following association:

  • Store Reference -> Name
  • Address -> Address (Full)
  • Title -> Title
  • Template -> Template

- If the Error Report window is displayed, it's possible some coordinates are not found. Double-Click on the line of the concerned marker and modify the name of the street or the city, then close the window.

5. In the main menu, use Publish option > On my server (Download) or Online on Click2Map's servers.

6. Change the options and parameters as needed and click on the OK button to publish the map. Read How to publish on website or share a map?

Why wait?

Start mapping now!