diff --git a/vpd-manager/include/error_codes.hpp b/vpd-manager/include/error_codes.hpp
index 6b4eb76..0665709 100644
--- a/vpd-manager/include/error_codes.hpp
+++ b/vpd-manager/include/error_codes.hpp
@@ -41,7 +41,8 @@
     FAILED_TO_DETECT_LOCATION_CODE_TYPE,
     RECEIVED_INVALID_KWD_TYPE_FROM_DBUS,
     INVALID_KEYWORD_LENGTH,
-    INVALID_VALUE_READ_FROM_DBUS
+    INVALID_VALUE_READ_FROM_DBUS,
+    RECORD_NOT_FOUND
 };
 
 const std::unordered_map<int, std::string> errorCodeMap = {
@@ -78,6 +79,7 @@
     {error_code::FILE_SYSTEM_ERROR, "File system error."},
     {error_code::INVALID_KEYWORD_LENGTH, "Invalid keyword length."},
     {error_code::INVALID_VALUE_READ_FROM_DBUS, "Invalid value read from DBus"},
+    {error_code::RECORD_NOT_FOUND, "Record not found."},
     {error_code::FAILED_TO_DETECT_LOCATION_CODE_TYPE,
      "Failed to detect location code type"},
     {error_code::DBUS_FAILURE, "Dbus call failed"},
diff --git a/vpd-manager/include/utility/vpd_specific_utility.hpp b/vpd-manager/include/utility/vpd_specific_utility.hpp
index 4d36c7b..cb85ceb 100644
--- a/vpd-manager/include/utility/vpd_specific_utility.hpp
+++ b/vpd-manager/include/utility/vpd_specific_utility.hpp
@@ -567,18 +567,22 @@
  *
  * @param[in] i_JsonObject - Any JSON which contains CCIN tag to match.
  * @param[in] i_parsedVpdMap - Parsed VPD map.
+ * @param[out] o_errCode - To set error code in case of error.
  *
  * @return True if found, false otherwise.
  */
 inline bool findCcinInVpd(const nlohmann::json& i_JsonObject,
-                          const types::VPDMapVariant& i_parsedVpdMap) noexcept
+                          const types::VPDMapVariant& i_parsedVpdMap,
+                          uint16_t& o_errCode) noexcept
 {
     bool l_rc{false};
     try
     {
-        if (i_JsonObject.empty())
+        if (i_JsonObject.empty() ||
+            std::holds_alternative<std::monostate>(i_parsedVpdMap))
         {
-            throw std::runtime_error("Json object is empty. Can't find CCIN");
+            o_errCode = error_code::INVALID_INPUT_PARAMETER;
+            return l_rc;
         }
 
         if (auto l_ipzVPDMap = std::get_if<types::IPZVpdMap>(&i_parsedVpdMap))
@@ -586,17 +590,16 @@
             auto l_itrToRec = (*l_ipzVPDMap).find("VINI");
             if (l_itrToRec == (*l_ipzVPDMap).end())
             {
-                throw DataException(
-                    "VINI record not found in parsed VPD. Can't find CCIN");
+                o_errCode = error_code::RECORD_NOT_FOUND;
+                return l_rc;
             }
 
-            uint16_t l_errCode = 0;
             std::string l_ccinFromVpd{vpdSpecificUtility::getKwVal(
-                l_itrToRec->second, "CC", l_errCode)};
+                l_itrToRec->second, "CC", o_errCode)};
             if (l_ccinFromVpd.empty())
             {
-                throw DataException("Can't find CCIN, error : " +
-                                    commonUtility::getErrCodeMsg(l_errCode));
+                o_errCode = error_code::KEYWORD_NOT_FOUND;
+                return l_rc;
             }
 
             transform(l_ccinFromVpd.begin(), l_ccinFromVpd.end(),
@@ -622,24 +625,12 @@
         }
         else
         {
-            logging::logMessage("VPD type not supported. Can't find CCIN");
+            o_errCode = error_code::UNSUPPORTED_VPD_TYPE;
         }
     }
     catch (const std::exception& l_ex)
     {
-        const std::string l_errMsg{
-            "Failed to find CCIN in VPD. Error : " + std::string(l_ex.what())};
-
-        if (typeid(l_ex) == std::type_index(typeid(DataException)))
-        {
-            EventLogger::createSyncPel(
-                types::ErrorType::InvalidVpdMessage,
-                types::SeverityType::Informational, __FILE__, __FUNCTION__, 0,
-                l_errMsg, std::nullopt, std::nullopt, std::nullopt,
-                std::nullopt);
-        }
-
-        logging::logMessage(l_errMsg);
+        o_errCode = error_code::STANDARD_EXCEPTION;
     }
     return l_rc;
 }
diff --git a/vpd-manager/src/worker.cpp b/vpd-manager/src/worker.cpp
index 520fc20..48d4dc8 100644
--- a/vpd-manager/src/worker.cpp
+++ b/vpd-manager/src/worker.cpp
@@ -1252,6 +1252,8 @@
 
     // Check if post action tag is to be triggered in the flow of collection
     // based on some CCIN value?
+    uint16_t l_errCode = 0;
+
     if (m_parsedJson["frus"][i_vpdFruPath]
             .at(0)["postAction"][i_flagToProcess]
             .contains("ccin"))
@@ -1267,15 +1269,23 @@
         if (!vpdSpecificUtility::findCcinInVpd(
                 m_parsedJson["frus"][i_vpdFruPath].at(
                     0)["postAction"]["collection"],
-                i_parsedVpd.value()))
+                i_parsedVpd.value(), l_errCode))
         {
+            if (l_errCode)
+            {
+                // ToDo - Check if PEL is required in case of RECORD_NOT_FOUND
+                // and KEYWORD_NOT_FOUND error codes.
+                logging::logMessage("Failed to find CCIN in VPD, error : " +
+                                    commonUtility::getErrCodeMsg(l_errCode));
+            }
+
             // If CCIN is not found, implies post action processing is not
             // required for this FRU. Let the flow continue.
             return true;
         }
     }
 
-    uint16_t l_errCode = 0;
+    l_errCode = 0;
     if (!jsonUtility::executeBaseAction(m_parsedJson, "postAction",
                                         i_vpdFruPath, i_flagToProcess,
                                         l_errCode))
