Is there a way to take a json string that contains field names and values and map the to an appropriate file (dynamically)?
Here is a sample DB file layout:
Here is a sample json string:
Is there a way to map those values to a record? I tried using vvin_json, but it seems you need to have a json string that matches an exact record layout for it to work properly.
Here is a sample DB file layout:
Code:
A PARTNO R REFFLD(PARTNO) A PARTDESC R REFFLD(DESC) A PARTTYPE R REFFLD(TYPE) A CATEGORY R REFFLD(CATEGORY) A COST R REFFLD(COST) A QTY R REFFLD(QUANTITY)
Here is a sample json string:
Code:
[ {"PARTNO":"ABC123","PARTDESC":"AIR FILTERXXX","PARTTYPE":"X"}, "PARTNO":"ABC999","PARTDESC":"AIR FILTERYYY","CATEGORY":"XXXXX"} ]
Comment