Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-4116

LOAD_FILE() does not understand paths with '\'

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Not a Bug
    • Affects Version/s: 10.0.0, 5.5.28a, 5.3.11, 5.2.13, 5.1.66
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      WinXP

      Description

      If I specify file path using '\' (which is usually used on Windows) LOAD_FILE() doesn't find the file, while it works using '/'.

      Create test.sql and issue:

       
      SELECT LOAD_FILE('c:\test.sql'), LOAD_FILE('c:/test.sql');
      

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            wlad Vladislav Vaintroub added a comment -

            In MySQL, backslash is used as mask character inside the string : http://dev.mysql.com/doc/refman/5.5/en/string-literals.html

            If you need a string with backslash, you'd need to duplicate it , e.g C:
            test.sql

            Show
            wlad Vladislav Vaintroub added a comment - In MySQL, backslash is used as mask character inside the string : http://dev.mysql.com/doc/refman/5.5/en/string-literals.html If you need a string with backslash, you'd need to duplicate it , e.g C: test.sql

              People

              • Assignee:
                Unassigned
                Reporter:
                f_razzoli Federico Razzoli
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: