Goanywhere FTP Uploaded Trigger Insert to SQL DB

If you have a new question you’d like our support staff to post a response to, please visit our customer community, Data Security Insiders, to pose the question in our Discussion Boards. We have a thread “Ask Our Tech Experts” that our support team monitors on a regular basis, or you can start a new discussion where other GoAnywhere users and support staff can weigh in. Log in or create your new account at https://insiders.helpsystems.com/sign_in.

If you need an immediate response, please create a support ticket or contact our support team by email at [email protected].
3 posts Page 1 of 1


Posts: 4
Joined: Thu Aug 04, 2016 1:04 am

Post by weesiong » Sat Apr 08, 2017 12:57 am
Hi All,

Do you have any sample project configuration for below case?
  • When file uploaded successfully into FTP Server, use the Trigger call a project, insert the filename into SQL DB.
Thank you.

Best regards,


Support Specialist
Posts: 592
Joined: Tue Jul 17, 2012 2:12 pm
Location: Phoenix, AZ

Post by Support_Rick » Sat Apr 08, 2017 10:25 pm
This is a utility I created several years back... it should do what you're looking for.
Code: Select all
<project name="Write File Stats"
	<variable name="trg_filename"
	          value="" />
	<variable name="trg_filesize"
	          value="" />
	<variable name="trg_filetype"
	          value="" />
	<variable name="trg_lastmod"
	          value="" />
	<variable name="trg_trantype"
	          value="" />
	<variable name="trg_projname"
	          value="" />
	<variable name="trg_jobid"
	          value="" />
	<variable name="trg_begtime"
	          value="" />
	<variable name="trg_endtime"
	          value="" />

	<module name="Main">

		<print label="(Status) Error Specs"
** JobLog **
Placing data into ${ LogFile } on ${ Server } Resource
  filename        ${ trg_filename }
  filesize        ${ trg_filesize }
  filetype        ${ trg_filetype }
  lastmod         ${ trg_lastmod }
  trantype        ${ trg_trantype }
  projname        ${ trg_projname }
  jobid           ${ trg_jobid }
  begtime         ${ trg_begtime }
  endtime         ${ trg_endtime }

		<setVariable label="Init sqlERROR"
		             version="1.0" />

		<sql label="Connect to Server"
			<query label="Put Log Rec">
Insert into ${ LogFile }
       ( filename, filesize, filetype, lastmod, trantype, projname, jobid, begtime, endtime )
Values ( &apos;${ trg_filename }&apos;,
         ${ trg_filesize } ,
         &apos;${ trg_filetype }&apos;,
         &apos;${ trg_lastmod }&apos;,
         &apos;${ trg_trantype }&apos;,
         &apos;${ trg_projname }&apos;,
         &apos;${ trg_jobid }&apos;,
         &apos;${ trg_begtime }&apos;,
         &apos;${ trg_endtime }&apos; )

		<if label="Error Inserting Data?"
		    condition="${ sqlERROR gt 0 }">

			<print label="SQL Insert Error?"
** JobLog Error **
Error Placing data into ${ LogFile } on ${ Server } Resource


	<variable name="Server"
	          value="Stats DB"
	          description="Log Server ResourceID" />
	<variable name="LogFile"
	          description="Log Table" />
	<description>Write entry to File Stats Database in GoA_Stats DB</description>
Rick Elliott
Lead Solutions Consultant
(402) 944.4242
(800) 949-4696


Posts: 4
Joined: Thu Aug 04, 2016 1:04 am

Post by weesiong » Sun Apr 09, 2017 10:38 pm
Thank you, will try :)
3 posts Page 1 of 1