You are viewing limited content. For full access, please sign in.

Question

Question

Empty numeric's field return an error when I'm importing

asked on April 26, 2018

Hi all,

 

I have a web form (simple Text Fields and Numeric Fields).

After submitting the form, my workflow populate my database.

 

Some fields are not required (like phone).

 

 

In my Database, I allow Nulls Value for my Phone (translate : "telephone")

 

Now what's happens.

From LFForm :

if my phone's field is populated => My workflow works.

if my phone's field is empty => My workflow doesn't work.

 

 

When my field is empty, I have a SQL Error

But in my mind, this is not true because my phone's field should be empty and can be added in my Database as I allow null's value, right?

 

I don't know If I should change something under the Workflow, the Form or my SQL.

Someone can help me?

Regards

 

0 0

Answer

SELECTED ANSWER
replied on April 26, 2018

Blank/empty is not null when it comes to SQL and Numeric type fields do not allow blanks. The recommendation here us to use the #NULL# formatter as seen here in your insert/update statement tokens. This is basically the equivalent of the SQL NULLIF()

 

https://www.laserfiche.com/support/webhelp/Laserfiche/10/en-US/administration/#../Subsystems/LFWorkflow/Content/Resources/Tokens%20and%20Regex/Token%20Formatting--Empty%20Tokens.htm

2 0

Replies

replied on April 27, 2018

What do your phone number values look like?

0 0
replied on April 27, 2018

Hi all and thank you.

@Miruna our phone number values look like 40000000 < (\d{8}) < 40999999

Exemple : 40436654

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.