Problem with Imports on Zoho Reports C# api
I'm having no luck getting bulk Import function to work with the c# api library. I can add or update rows to a Zoho database table just fine but when I try to use the ImportData function I get nothing. I don't even get a response so I can debug what I'm sending. I am trying to import a JSON data string but I have had no luck importing from a file either.
Does the free version of Zoho Reports not allow API Imports?
I pasted my code snippet below. I have tried every combination of settings for ImportConfig that I can think of. Any help would be greatly appreciated!
public static void ImportSales(List<ZohoSale> lzs)
{
var json = JsonConvert.SerializeObject(lzs);
IReportClient RepClient = getClient();
string tableURI = RepClient.GetURI(UserAccountEmail, DatabaseName, TableName);
Dictionary<string, string> ImportConfig = new Dictionary<string, string>();
ImportConfig.Add("ZOHO_ON_IMPORT_ERROR", "ABORT");
ImportConfig.Add("ZOHO_ERROR_FORMAT", "JSON");
ImportConfig.Add("ZOHO_CREATE_TABLE", "TRUE");
ImportConfig.Add("ZOHO_IMPORT_FILETYPE", "JSON");
ImportConfig.Add("ZOHO_AUTO_IDENTIFY", "TRUE");
ImportConfig.Add("ZOHO_CRITERIA", "SaleId");
ImportConfig.Add("ZOHO_IMPORT_DATA", json);
ImportConfig.Add("ZOHO_MATCHING_COLUMNS", "ProductName,CountOrdered,Price");
ImportConfig.Add("ZOHO_API_VERSION", "1,0");
Dictionary<string, string> ImportRes = RepClient.ImportData(
tableURI, ZohoReportsConstants.UPDATEADD, "C:\\workspace\\generated.json", ImportConfig);
}
Access your files securely from anywhere
Zoho Developer Community
Deliver unforgettable customer experiences
Deliver unforgettable customer experiences
New to Zoho Marketing Plus?
Everything you need to run your marketing
New to Zoho Marketing Plus?
Everything you need to run your marketing
Zoho Desk Resources
-
Desk Community Learning Series
-
-
-
-
-
-
-
-
-
Zoho TeamInbox Resources
Zoho DataPrep Resources
Zoho CRM Plus Resources
Zoho Books Resources
Zoho Subscriptions Resources
Zoho Projects Resources
Zoho Sprints Resources
Qntrl Resources
Zoho Creator Resources
Zoho Campaigns Resources
Zoho CRM Resources
Zoho Show Resources
Writer Get Started. Write Away!
Writer is a powerful online word processor, designed for collaborative work.