Upload and Import CSV via API

Answered

Comments

2 comments

  • Jonathan Sala

    Solved it! I hadn't included the extension in the $fileName - changing that to "example.csv" got Podio to recognise the filetype.
    Additionally, I had the column_ids mapping to 0 and 1 instead of "0" and "1".

    0
    Comment actions Permalink
  • Victoria Aparicio

    Hello, I have a problem to import more than one column, I have a csv file, I import the first(0), but I can't import the others .
    This is my code
    $importResult = PodioImporter::process_app( $importFile->id, 14063765, array(
    "app_id" => 14063765,
    "mappings" => array(
    array(
    "field_id" => 107643862,
    "unique" => false,//True of the values for the field is unique, false otherwise,
    "value" => array(
    "column_id" => "0",
    "value_column_id" => 'RadarID'
    )
    ),
    array( "field_id" => 107643863,
    "unique" => false,//True of the values for the field is unique, false otherwise,
    "value" => array(
    "column_id" => "1",
    "value_column_id" => 'APN'
    ))
    )
    ) );
    the file is:
    RadarID,APN,County,Address,City,State,Zip,Subdivision,LotNumber,Owner,OwnerFirstName,OwnerLastName,OwnerSpouseFirstName,Owner2,OwnerAddress,OwnerCity,OwnerState,OwnerZip,OwnerPhone,PrimaryResidence,PropertyType,Units,SqFt,YearBuilt,Beds,Baths,LotSize,Pool,Stories,EstimatedValue,EstimatedTotalLoanBalance,EquityPercent,AssessedValue,AssessedYear,AnnualTaxes,TaxRateArea,inForeclosure,FirstLoanLender,FirstLoanDate,FirstLoanAmount,SecondLoanLender,SecondLoanDate,SecondLoanAmount,TransferDate,TransferAmount,ListedForSale,ListingType,ListingPrice
    P1057ED1,5041-036-031,LOS ANGELES,1625 EXPOSITION BLVD,LOS ANGELES,CA,90018,4014,175,"DAVIS,VELOCIA E",VELOCIA,DAVIS,,,2528 THORNGROVE CT,FAYETTEVILLE,NC,28303,,0,SFR,1,792,1923,1,1,3875,0,1,278064,0,100,95409,2015,1304,67,0,,,,,,,5/9/86,58000,0,,

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk