I have an input file like:
INFO 2016-06-15 00:10:43.173WMSPackingOrderManager llocatePackingOrderToWorkplaceBoxed -Remaining capacity of workplace WMSPackingWorkplace[428654,PAC_MB_ 104] is -43
INFO 2016-06-15 00:30:43.173WMSPackingOrderManager llocatePackingOrderToWorkplaceBoxed -Remaining capacity of workplace WMSPackingWorkplace[428654,PAC_MB_ 104] is -43
INFO 2016-06-15 00:30:43.173WMSPackingOrderManager llocatePackingOrderToWorkplaceBoxed -Remaining capacity of workplace WMSPackingWorkplace[428654,PAC_MB_ 104] is -43
INFO 2016-06-15 00:30:43.173WMSPackingOrderManager llocatePackingOrderToWorkplaceBoxed -Remaining capacity of workplace WMSPackingWorkplace[428654,PAC_MB_ 104] is -43
INFO 2016-06-15 00:30:43.173WMSPackingOrderManager llocatePackingOrderToWorkplaceBoxed -Remaining capacity of workplace WMSPackingWorkplace[428654,PAC_MB_ 104] is -43
The code I currently have is as follows:
cat inputFile.log | awk -v date="2016-06-15" -v startTime="00:10" -v endTime="00:20" '$2" "$3>=from&&$2" "$3<=to' from=date" "startTime to=date" "endTime
I am trying to get the from and to to use the variables provided but to no luck. I have tried escaping the special characters with \ but this didn't seem to effect it.
cat file | awk '...', sinceawk '...' filedoes the same.