Replace_null not working

  • 18Views
  • Last Post 2 weeks ago
0
votes
Jacques Corby-Tuech posted this 3 weeks ago

Hi, I'm trying to import data into Zoho CRM and am having some issues with the replace_null function, which is not working as expected.

I am trying to map last_name from my database to the last name field in Zoho. As this is a required field in Zoho and as some values are null in my database I am using the following function to provide a value in instances where the last_name is null.

replace_null(last_name,'-')

 

When running this task, rows that contain a null value are failing to be imported.

Is there something wrong with my expression? Any help would be appreciated.

 

Order By: Standard | Newest | Votes
0
votes
Mariia Zaharova posted this 3 weeks ago

Hello Jacques,

 

Thank you for contacting our Skyvia Team!

 

You can use these expressions for your scenario:

1) Old runtime (the "Use new runtime" checkbox is not selected in your package):

(last_name == "" || isnull(last_name)) ? "-" : last_name

 

2) New runtime (the "Use new runtime" checkbox is selected in your package):

(last_name == '' || isnull(last_name)) ? '-' : last_name

or

is_null_or_empty(last_name) ? '-' : last_name

 

Please tell us if this helps.

 

Best regards,

Mariia

0
votes
Jacques Corby-Tuech posted this 3 weeks ago

Hi Mariia,

This is sort of working, I'm seeing less errors than before but I'm still seeing some errors like this:


Error: required field not found. Details: {"api_name":"Last_Name"}.

Thanks,
Jacques

0
votes
Mariia Zaharova posted this 2 weeks ago

 Hello Jacques,

 

Thank you for your reply.

 

Please open Query Tool (+ New -> Query -> SQL), select your PostgreSQL connection, execute and save results of this query to CSV file:

SELECT t.last_name

  FROM public.auth_user AS t

 

Please send us this CSV file.

 

Best regards,

Mariia

Close