Opened 3 years ago

Closed 3 years ago

Last modified 7 months ago

#2426 closed New feature (fixed)

LOAD DATA (LOCAL) INFILE - pick "best" strategy at runtime

Reported by: vipsoft Owned by: vipsoft
Priority: normal Milestone: 1.5 - Piwik 1.5
Component: Core Keywords:
Cc: Sensitive: no

Description

The current algorithm is to first attempt "LOCAL", and then "REMOTE".

The new strategy is to look at the host name, and if it appears local, try LOAD DATA LOCAL INFILE first. Conversely, if it appears to be remote, try LOCAL DATA INFILE first. Then fallback to the other case.

Change History (5)

comment:1 Changed 3 years ago by vipsoft (robocoder)

  • Resolution set to fixed
  • Status changed from new to closed

(In [4685]) fixes #2426

comment:3 Changed 3 years ago by vipsoft (robocoder)

This fixes the issue reported by Monica/Anton on the forum. Windows Server 2008, php 5.3.2 --with-pdo-mysql=mysqlnd, adapter=PDO_MYSQL, MySql 5.1.45, and "local infile = on", Piwik_Exec('LOAD DATA LOCAL INFILE ...') throws an exception ($e->getMessage() is empty), and subsequent queries (ie fallback) all fail.

comment:4 Changed 3 years ago by vipsoft (robocoder)

(In [4687]) refs #2426 - can skip LOCAL under some conditions

comment:5 Changed 7 months ago by matt (mattab)

Last edited 7 months ago by matt (previous) (diff)
Note: See TracTickets for help on using tickets.