0
[
    {
        "Product_ID": "24222",
        "Product_SKU": "406",
    }, {
        "Product_ID": "24218",
        "Product_SKU": "464",
    }, {
        "Product_ID": "24211",
        "Product_SKU": "231",
    }, {
        "Product_ID": "24212",
        "Product_SKU": "231",
    }, {
        "Product_ID": "24213",
        "Product_SKU": "231",
    }, {
        "Product_ID": "24207",
        "Product_SKU": "076",
    }, {
        "Product_ID": "24208",
        "Product_SKU": "076",
    }, {
        "Product_ID": "24202",
        "Product_SKU": "075",

    }
]

Hello I added example json file.How can i get count of unique values of Product_SKU ?I try many thing and searched same issues in stackoverflow but i cant find solution.Someone can help me ?

SOLUTION : count(array_unique(array_column($yourArray, "Product_SKU")));

THANK YOU : Esteban MANSART

babax
  • 1
  • 4

0 Answers0