Pick the column value based on another column from .csv file

My scenario is that I need to pick value from third column based on fourth column value, if fourth column value is 1 then first value of third column.Third column (2|3|4|6|1) values are cancatenated.
Main imp point, in my .csv file, third column is having price value with comma (1,20,300), it has to be considered 1,000 as single column.
Please someone help me to resolve this issue.

Source file format

column1 column2 column 3 column4 column5
1,ganesh,1,000,2,1
222,ram,2,000,2|3,1
222,ram,5,000,2|3,2
33,raju,5,000,2|5|4|6|1,1
33,raju,5,000,2|8|4|6|1,2
33,raju,5,000,2|9|4|6|1,3
33,raju,5,000,2|8|4|6|1,4
33,raju,5,000,2|3|4|6|1,5

Target output

column1 column2 column3 column4 
1,ganesh,1,000,2,1
222,ram,2,000,2,1
222,ram,5,000,3,2
33,raju,5,000,2,1
33,raju,5,000,8,2
33,raju,5,000,4,3
33,raju,5,000,6,4
33,raju,5,000,1,5

try:

awk -F, '/,/ {split($5,arr, "|"); $5=arr[$6]} 1' OFS=, infile

Thanks for the solution... I will try this code and let u know the status