hi hi all. any chance anyone has a pyflink example...
# pyflink
g
hi hi all. any chance anyone has a pyflink example where you consume a json object as a string contained in single column/field and insert it into a table... jsonified using pyflink.
d
g
I have a 4 column table, one column is called "data" of type string, which contains the below. need to extract the "account" tag and insert into it's own table => accounts, each record being a row
Copy code
{
  "_id": "152b85fb-a83b-4d6b-8006-76cbd94850e1",
  "name": "Fergal",
  "surname": "Freeley",
  "nationalid": "2023852B",
  "gender": "M",
  "dob": "05/10/16",
  "marital_status": "Married",
  "partner": "7733541K",
  "status": "Living",
  "account": [
    {
      "fspiAgentAccountId": "BARCIE2D-32370059",
      "accountId": "32370059",
      "fspiId": "BARCIE2D",
      "fspiAgentId": "BARCIE2D",
      "accountType": "Current Accounts",
      "memberName": "Barclays Bank Ireland plc"
    },
    {
      "fspiAgentAccountId": "BOFIIE2D-68831794",
      "accountId": "68831794",
      "fspiId": "BOFIIE2D",
      "fspiAgentId": "BOFIIE2D",
      "accountType": "Savings/Deposit",
      "memberName": "Bank of Ireland plc"
    },
    {
      "fspiAgentAccountId": "BARCIE2D-71834892",
      "accountId": "71834892",
      "fspiId": "BARCIE2D",
      "fspiAgentId": "BARCIE2D",
      "accountType": "Savings/Deposit",
      "memberName": "Barclays Bank Ireland plc"
    },
    {
      "fspiAgentAccountId": "AIBKGB2-31430193",
      "accountId": "31430193",
      "fspiId": "AIBKGB2",
      "fspiAgentId": "AIBKGB2",
      "accountType": "Savings/Deposit",
      "memberName": "Allied Irish Banks plc"
    },
    {
      "cardHolder": "F Freeley",
      "cardNumber": "4420159224478543",
      "expDate": "10/25",
      "cardNetwork": "Visa",
      "issuingBank": "Allied Irish Banks plc"
    }
  ],
  "address": {
    "street_1": "90 Gilgunn Street Street",
    "street_2": "",
    "neighbourhood": "Carrick Road",
    "town": "Boyle",
    "county": "Roscommon",
    "province": "Connacht",
    "country": "Ireland",
    "country_code": "IE",
    "postal_code": "F52 T3N8",
    "parcel_id": "F52 T3N8-16688"
  }
}
bump.
d
@George Leonard Do you encountered some problems?
It would be great if you could describe the actual problems encountered or show some code snippets to see where you have doubt.
g
see my post. im asking if anyone have a example, as the ideas i had is not working and need a nudge in right direction.