MariaDB - select ... into outfile

Hallo OTRS-Community, für den Datenaustausch mit einem anderen System möchte ich einfach eine *.csv-Datei per SQL-Statement mittels SQLBox (OTRS-Admin-Bereich) erstellen lassen. Über select substring(a.a_subject,35) as num3, t.tn as yotrsnr into outfile '/opt/otrs/var/OTRS.S1234.txt' fields TERMINATED BY ';' optionally ENCLOSED BY '"' escaped BY '\\' lines TERMINATED BY '\n' from ticket t, article a where t.id=a.ticket_id and t.ticket_state_id = 1 and t.queue_id=22 and t.id=1570; soll testweise die Datei geschrieben werden. Dabei erhalte ich jedoch im OTRS-Logfile die Fehlermeldung: [Thu Oct 12 14:23:18 2017] [Error][Kernel::Modules::AdminSelectBox::Run][93] Access denied for user 'otrs'@'localhost' (using password: YES), SQL: 'select substring(a.a_subject,35) as num3, t.tn as yotrsnr into outfile '/tmp/OTRS.S1234.txt' fields TERMINATED BY ';' optionally ENCLOSED BY '"' escaped BY '\\' lines TERMINATED BY '\n' from ticket t, article a where t.id=a.ticket_id and t.ticket_state_id = 1 and t.queue_id=22 and t.id=1570;' Wie kann ich nun diese Textdatei schreiben? Vielen Dank Gruß Sepp
participants (1)
-
Josef Penzkofer