Hi All,We have one DCT which is fetching data from another DCT.For example we have one DCT named as Target and another DCT named as Source.We fetch all the dcrs from Source/data in the dropdown of Target.For this we have one perl script which is executing during the form initialization of Target.In that perl script we are checking that whether Source/data is directory then only it will fetch all the files in the dropdown of Target.For the first iteration it is working as expected but in second iteration we are not getting values in dropdown and during investigating we found that it is failing atif (-d "Source/data")Please suggestThanks in Advance
Without seeing more of the script and the entire environment (DCT, etc.) in which it is being executed - it is difficult to propose a fix - however, for debugging purposes I suggest you put a logging line above that test and have it print out the value (I'm assuming that there is really a variable there and not literally "Source/data")
Thanks Ghoti,Yes you are right there is variable as you can saymy spath = $mountname.$workarea. "/" . "teamplatedata/Source/data" ;if (-d $spath)We have put many loggers in loop level as well as variable levelIn the log we have seen that variable spath is giving expected value i.e directory but it is failing in IF condition.Let me know if you need more information
$logger->debug("SPATH: '$spath'");
As ghoti said it is hard to believe that value in $spath variable is coming correctly but your IF statement is not getting executed correctly. Are you sure that $mountname and $workarea are getting populated correctly all the times. It will not be possible help further without seeing the code.
Thanks Ghoti,Let me clear this that it is working for first instant but it get failed in second or third instant.I just want to confirm do we need anything from Admin perspective regarding this.Just to verify the code we have placed the same code in different server and there it worked as expected.
I don't know exactly what you mean by "first instan[ce]" versus "second or third instan[ce]". Is there a loop? Or are you doing some sort of refresh causing the script to be run multiple times (once per refresh)? Or something else?As stated - make sure you have that debugging statement before the conditional (and probably one within as well) and then post the output that you see for both the successful and failed attempts.
Ghoti, Thats strange for us also to tell you that for first instance it is working but for second or third it is not working.Here instance means times,I mean to say that when we create New Form for first time then it is coming as expected but when we create New Form for second or third time the values went off.We have put as many loggers as we can and found that for first time it is getting into the loop if (-d $spath)and print the list of files which are available (As we put the logger for that)But when it failed it is by passing the IF LOOP and print only those statements which are output of this loop like Value of $spath.I hope this may clear my problem.
inline command="d:/iw-home/iw-perl/bin/iwperl.exe d:/iw-home/custom/inline/somescript.ipl"
You need to post the datacapture.cfg file, in addition it references a script, something like: inline command="d:/iw-home/iw-perl/bin/iwperl.exe d:/iw-home/custom/inline/somescript.ipl" Get rid of the since you are unix
Actually, since their on Unix - they can get rid of the "d:/iw-home/iw-perl/bin/iwperl.exe" part completely (not only won't .exe work - but if you have the right #! line and the script is executable you should be good.