DMXzone Database Updater ASP Support Product Page
Under consideration
How to set date/time field to NULL
Shared 8 years ago
1
likes this idea
8 years ago MX Addict posted:
When insert/update a empty textfield to datatype date/time in SQL server. I get the field filled with 1899-12-31T05:00:00Z. It is not possible with this extension to assign a NULL value. The Dreamweaver insert/update behaviours did work with a function:
< %' IIf implementation Function MM_IIf(condition, ifTrue, ifFalse) If condition = "" Then MM_IIf = ifFalse Else MM_IIf = ifTrue End If End Function %>
MM_IIF(Request.Form("date"), Request.Form("date"), null))
I need to insert/update a empty value in date/time
Replies
Replied 8 years ago
8 years ago MX Addict replied:
Miroslav told during live support to write a topic about this question. But two weeks further still no response.
Replied 8 years ago
8 years ago Teodor Kuduschiev replied:
Hello,
This is currently not possible. WE will discuss this idea with the team and will try to integrate this feature in the upcoming updates/releases.
This is currently not possible. WE will discuss this idea with the team and will try to integrate this feature in the upcoming updates/releases.
Replied 8 years ago
8 years ago MX Addict replied:
That will be nice. I need a date/time field that can be empty (Null)
Replied 8 years ago
8 years ago MX Addict replied:
When will this be solved. I still need Null value for date/time
Replied 8 years ago
8 years ago MX Addict replied:
Hi Teodor,
Still waiting to set Null value for date/time database field
Still waiting to set Null value for date/time database field
Replied 8 years ago
8 years ago Teodor Kuduschiev replied:
Hello,
You can try using:
in the value you insert to your db. Example - if you are inserting {{$_POST.date}} it should become {{$_POST.date.default(null)}}
Please let me know if this properly inserts a null value into the database field.
You can try using:
.default(null)
in the value you insert to your db. Example - if you are inserting {{$_POST.date}} it should become {{$_POST.date.default(null)}}
Please let me know if this properly inserts a null value into the database field.
Replied 8 years ago
8 years ago MX Addict replied:
Hi Teodor,
This doesn't work.
you can test the page with the link i send you yesterday
In my api file
"table": "tbl_test",
"column": "datum",
"value": "{{$_POST.hidden_datum.default(\"null\"
}}",
"type": "datetime"
I use a hidden_datum field with Calendar 3. Has it to with this?
This doesn't work.
you can test the page with the link i send you yesterday
In my api file
"table": "tbl_test",
"column": "datum",
"value": "{{$_POST.hidden_datum.default(\"null\"

"type": "datetime"
I use a hidden_datum field with Calendar 3. Has it to with this?
Replied 8 years ago
8 years ago Teodor Kuduschiev replied:
Hidden field is not the issue. I will check this with our developers.