I need to design an interface , where we process a set of input files and then load them into the database tables . After loading , we need to wait until we get next input file from other interface , until then we should not proceed with our task. Need help how this can be achieved.
Step 1 ; Load the input file from \usr\interface\input\dat1.csv , dat2.csv , dat3.csv , dat4.csv
Step 2: After loading wait for the input file from other interface \usr\interface\remote\input\list.csv
Step 3: If file is found or ftpied in the remote folder in step 3 , load the list.csv in the database tables.
Step 4: Compare the data loaded from step1 and step 4.
I need help on the step2 , how to interrupt the unix process to wait for an infinite time until a file is ftpied in the remote directory.
Any help or guidance is really appreciated.