Date value can't be set or changed

Chucky

New member
Hi gang,

Thanks for this great program, but I can't get it running right now:

I have a date field in my table, and that's the problem. Neither editing nor adding records is possible, as the date value seems not to be transported in the query string coming from dadabik:
Trying to add a record:
INSERT INTO `tour` (`date`, `time`, `venue`, `street`, `city`, `zip`, `country`, `cou`, `ticket`, `phone`, `online`, `lat`, `lng`, `sspn_1`, `sspn_2`, `user`) VALUES (, '20.00', 'test', '', '', '', '', '', '', '', '', '', '', '', '', '')
Trying to edit a record:
UPDATE `tour` SET `date` = , `time` = '20:00:00', `venue` = 'Lahr', ... ...

In both you see that the date field has no value that could be send to the database.
Yes, the database field is date format, both dadabik and mysql database. No, no other date in there. Yes, I tried different versions of date format in databik, both english and latin. Yes, I can edit dates and records manually in myadmin.

I use dadabik 4.4 alpha, MySQL-Client-Version: 5.0.51a

I appreciate your help,

Chuck
 

Chucky

New member
Yes, Debbie...

BTW: Version 4.3 works proper with my tables, so it may be a programming bug in 4.4?

Cheers
Chuck
 

DebbieS

DaDaBIK Guru
Could likely be ... Eugenio can check on that ...
For any production system, it is always recommended to use the latest stable version.
 

eugenio

Administrator
Staff member
This is definitely a 4.4 alpha bug, thanks for having reported it Chucky.
It will be fixed and published in the 4.4 beta release.
 

eugenio

Administrator
Staff member
Here is the fix:

file db_functions_adodb.php
function format_date_for_dbms

change:
return $conn->$date;
with
return $conn->DBDate($date);

the fix will also be available in dadabik 4.4 beta, coming soon.
 
Top