DaDaBIK
This forum is devoted to the discussion about the software DaDaBIK database front-end
the PHP Database application generator for MySQL, PostgreSQL and SQLite; also available for Wordpress.

Welcome! Log In Create A New Profile

Advanced

Date value can't be set or changed

Posted by Chucky 
Date value can't be set or changed
February 13, 2011 03:27PM
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
Re: Date value can't be set or changed
February 13, 2011 05:47PM
Do you have a primary key set in each table you are trying to manage with DaDaBIK?

_______________________________
..:: Debbie |\.-./| DaDaBIK Support ::..
Re: Date value can't be set or changed
February 14, 2011 02:01AM
Yes, Debbie...

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

Cheers
Chuck
Re: Date value can't be set or changed
February 14, 2011 04:01PM
Could likely be ... Eugenio can check on that ...
For any production system, it is always recommended to use the latest stable version.

_______________________________
..:: Debbie |\.-./| DaDaBIK Support ::..
Re: Date value can't be set or changed
February 15, 2011 01:30PM
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 |\.-./| DaDaBIK developer and project admin
Re: Date value can't be set or changed
April 21, 2011 02:34AM
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.

________________________________________________________
Eugenio |\.-./| DaDaBIK developer and project admin
Sorry, only registered users may post in this forum.

Click here to login