J
J
John Doe2018-10-12 08:28:59
FTP
John Doe, 2018-10-12 08:28:59

How to create an entry in the table immediately after the file is fully uploaded through ProFTPD?

I understand that you need to use SQLLog and SQLNamedQuery.

SQLLog RETR,STOR handle
SQLNamedQuery handle INSERT "'%f', %b, '%u', now()" uploadhistory

Answer the question

In order to leave comments, you need to log in

1 answer(s)
J
John Doe, 2018-10-12
@rabbit418

I looked in the logs and found the SQL error:
mod_sql/4.3: unrecoverable backend error: (1136) Column count doesn't match value count at row 1
Everything turned out to be easier than I thought, there was also an id field in the table that was AUTO_INCREMENT and it also had to be passed.
Solution to my problem for posterity:

SQLLog RETR,STOR handle
SQLNamedQuery handle INSERT "'', '%f', %b, '%u', now()" uploadhistory

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question