Problem after upgrade to DaDaBIK 11

AndyB

Member
Your current DaDaBIK version

You are using DaDaBIK version 11.0-Elba platinum, installed on 06-20-2021 (installation code: 151725e15dd6476c95), the latest version of DaDaBIK is

There are problems with the Internet connection, we cannot check if there are upgrades available.

In case you want to upgrade to a more powerful edition (from Pro to Enterprise/Platinum, from Enteprise to Platinum) please contact us.
System info

PHP Version: 7.1.33

mysql version: 5.5.5-10.3.29-MariaDB-cll-lve

Web server: LiteSpeed

Client: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:80.0) Gecko/20100101 Firefox/80.0

URL installation:

-----------------------------------------------------

I upgraded my database to DaDaBIK 11 and now get the error 'The DBMS server said: SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'Field' cannot be null' whe i try to insert a new record.
Any ideas what is wrong?
I've searched and cannot see anything that has changed.
Thanks

Andy
 

taubes

Member
Hi
Also a problem with the upgrade:
Upgraded an existing database using the zipped Elba file. so far so good.
However in the app I get this error message at the top above the <!DOCTYPE html>
Notice: Undefined index: status_installation in /Users/xxxx/include/check_login.php on line 0

I think there might be something wrong with upgrade.php as this causes a connection loss. I presume the database entries are not correctly upgraded.

A clean installation works fine but I would loose alle the DaDaBIK entries for the forms.

Any idea?

Thanks so much,

Stefan

INFO:
You are using DaDaBIK version 11.0-Elba platinum, installed on Jun 21, 2021 (installation code: [blanked this out here]), the latest version of DaDaBIK is 11.0-Elba released on Jun 17, 2021
You are runnning the latest release of DaDaBIK

System info
PHP Version: 7.2.34
mysql version: 8.0.23
Web server: Apache/2.4.46 (Unix) OpenSSL/1.1.1k PHP/7.2.34
Client: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.1.1 Safari/605.1.15
URL installation: https://localhost/~xxxxxx
 

eugenio

Administrator
Staff member
AndyB Wrote:
-------------------------------------------------------
> Your current DaDaBIK version
> I upgraded my database to DaDaBIK 11 and now get t
> he error 'The DBMS server said: SQLSTATE[23000]: I
> ntegrity constraint violation: 1048 Column 'Field'
> cannot be null' whe i try to insert a new record.
> Any ideas what is wrong?
> I've searched and cannot see anything that has cha
> nged.

Hello,
do you actually have a field called "field" in your tables? If yes, does the field allow NULL values?
The error doesn't seem dadabik-related, I think either you changed the field settings or your provider changed error-related settings for mysql?

Best,
 

eugenio

Administrator
Staff member
taubes Wrote:
-------------------------------------------------------
> Hi
> Also a problem with the upgrade:
> Upgraded an existing database using the zipped Elb
> a file. so far so good.
> However in the app I get this error message at the
> top above the <!DOCTYPE html>
> Notice: Undefined index: status_installation in /U
> sers/xxxx/include/check_login.php on line 0
>
> I think there might be something wrong with upgrad
> e.php as this causes a connection loss. I presume
> the database entries are not correctly upgraded.

Hello Stefan,
this is the sign that the new field status_installation has not be added so the upgrade process did not work as expected, did you get any error message during the upgrade?

Best,
 

AndyB

Member
Eugenio,

Sorry I changed the name to field in my post for reasons of privacy. The error message had a real field name in it.
The database worked fine before the upgrade and then gave the error after the upgrade.

Andy
 

eugenio

Administrator
Staff member
AndyB Wrote:
-------------------------------------------------------
> Eugenio,
>
> Sorry I changed the name to field in my post for r
> easons of privacy. The error message had a real fi
> eld name in it.
> The database worked fine before the upgrade and th
> en gave the error after the upgrade.
>
> Andy

Then check if such field admit the NULL value, I am pretty sure it doesn't and that's why you get the error.
Maybe before it worked because you had $treat_blank_as_null = 0, while now you have $treat_blank_as_null = 1, maybe you have lost your config params because you edited config.php instead of config_custom? $treat_blank_as_null is by default 1 since v. 10.2, before it was 0.

Best,
 

AndyB

Member
Eugenio,

Thanks, you gave me the information i needed to fix this, i had some fields in the database set to None instead of Null and i changed this.

However i now get a new error on trying to save a new file with revisions turned on.

[08] Error: during query execution. INSERT INTO `dadabik_revisions_ClockDataExpanded` (`UniqueNumberID`,`FormNo`,`Town`,`County`,`BuildingName`,`Dedication`,`Address`,`PostCode`,`LocationinBuilding`,`GridRef`,`PreviousLocation`,`PhotoClock`,`OtherLiterature`,`Comments`,`MakerSurname`,`MakerForename`,`MakerTown`,`DateonClock`,`DateCirca`,`Inscription`,`FrameType`,`FrameLength`,`FrameHeight`,`FrameDepth`,`FrameMaterial`,`GoingType`,`GoingTrainWheels`,`StrikingTrainWheels`,`ChimingTrainWheels`,`StrikeControl`,`TuneBarrel`,`Automata`,`T/GPInfo`,`GoingPeriod`,`Escapement`,`CompensationPendulum`,`PendLgthIns`,`PendPeriod`,`WindingSystem`,`MaintainingPower`,`ElectricalClocks`,`Autowinder`,`Dials`,`DialMaterial`,`Hands`,`DialDate`,`OtherDialInfo`,`ClockCondition`,`SurveyDate`,`UpdateDate`,`RecorderCode`,`OtherInfo`,`DataEnter`,`TypeOfBuilding`,`OtherFeature`,`AutowindMake`,`SignificanceGrade`,`DataUpdateDate`,`PhotoContext`,`PhotoDial`,`PhotoTrainCount`,`Remontoire`,`Sources`,`History`,`CarillonWheels`,`GoingWheelSize`,`StrikeWheelSize`,`ChimeWheelSize`,`CarillonWheelSize`,`CarillonControl`,`WeightDrop`,`PulleyConfig`,`PendulumCorrection`,`PendCorDate`,`PullOffMethod`,`DialSize`,`DialIllumination`,`LeadOffDetail`,`RecordStatus`,`CofEChurchCode`,`MakerSerialNo`,`LatLong`,`GoingDrumSize`,`StrikeDrumSize`,`ChimeDrumSize`,`CarillonDrumSize`,`StrikeType`,`ChimeType`,`ChimeTime`,`ExtractNo`,`FinialType`,`FinialPosition`,`DatePeriod`,`BPM`,`BPH`, dadabik_revision_username, dadabik_revision_date_time, dadabik_revision_operation) SELECT `UniqueNumberID`,`FormNo`,`Town`,`County`,`BuildingName`,`Dedication`,`Address`,`PostCode`,`LocationinBuilding`,`GridRef`,`PreviousLocation`,`PhotoClock`,`OtherLiterature`,`Comments`,`MakerSurname`,`MakerForename`,`MakerTown`,`DateonClock`,`DateCirca`,`Inscription`,`FrameType`,`FrameLength`,`FrameHeight`,`FrameDepth`,`FrameMaterial`,`GoingType`,`GoingTrainWheels`,`StrikingTrainWheels`,`ChimingTrainWheels`,`StrikeControl`,`TuneBarrel`,`Automata`,`T/GPInfo`,`GoingPeriod`,`Escapement`,`CompensationPendulum`,`PendLgthIns`,`PendPeriod`,`WindingSystem`,`MaintainingPower`,`ElectricalClocks`,`Autowinder`,`Dials`,`DialMaterial`,`Hands`,`DialDate`,`OtherDialInfo`,`ClockCondition`,`SurveyDate`,`UpdateDate`,`RecorderCode`,`OtherInfo`,`DataEnter`,`TypeOfBuilding`,`OtherFeature`,`AutowindMake`,`SignificanceGrade`,`DataUpdateDate`,`PhotoContext`,`PhotoDial`,`PhotoTrainCount`,`Remontoire`,`Sources`,`History`,`CarillonWheels`,`GoingWheelSize`,`StrikeWheelSize`,`ChimeWheelSize`,`CarillonWheelSize`,`CarillonControl`,`WeightDrop`,`PulleyConfig`,`PendulumCorrection`,`PendCorDate`,`PullOffMethod`,`DialSize`,`DialIllumination`,`LeadOffDetail`,`RecordStatus`,`CofEChurchCode`,`MakerSerialNo`,`LatLong`,`GoingDrumSize`,`StrikeDrumSize`,`ChimeDrumSize`,`CarillonDrumSize`,`StrikeType`,`ChimeType`,`ChimeTime`,`ExtractNo`,`FinialType`,`FinialPosition`,`DatePeriod`,`BPM`,`BPH`, 'root', '2021-06-21 22:20:43', 'insert' FROM `ClockDataExpanded` WHERE `` = '0'
The DBMS server said: SQLSTATE[42S22]: Column not found: 1054 Unknown column '' in 'where clause'

The save works ok with revisions turned off.

Thanks

Andy
 

AndyB

Member
I forgot to say that if i amend an exisitng record with revisions turned on it works ok and saves the revision data.

Regards

Andy
 

eugenio

Administrator
Staff member
AndyB Wrote:
-------------------------------------------------------
> Eugenio,
>
> Thanks, you gave me the information i needed to fi
> x this, i had some fields in the database set to N
> one instead of Null and i changed this.
>
> However i now get a new error on trying to save a
> new file with revisions turned on.

Probably you don't have a unique field set for that table?
 

eugenio

Administrator
Staff member
taubes Wrote:
-------------------------------------------------------
> Hi Eugenio,
>
> No I got NO error message during the installation.
>
> Best
>
> St

Hi,
do you mean during the upgrade?
Which upgrade procedure did you use?
 

AndyB

Member
Eugenio,

I setup a new unique field for this table to ensure it was ok and now when i try to save a new record i get the error-

[08] Error: during query execution. INSERT INTO `dadabik_revisions_ClockDataExpanded` (`RefNo`,`UniqueNumberID`,`FormNo`,`Town`,`County`,`BuildingName`,`Dedication`,`Address`,`PostCode`,`LocationinBuilding`,`GridRef`,`PreviousLocation`,`PhotoClock`,`OtherLiterature`,`Comments`,`MakerSurname`,`MakerForename`,`MakerTown`,`DateonClock`,`DateCirca`,`Inscription`,`FrameType`,`FrameLength`,`FrameHeight`,`FrameDepth`,`FrameMaterial`,`GoingType`,`GoingTrainWheels`,`StrikingTrainWheels`,`ChimingTrainWheels`,`StrikeControl`,`TuneBarrel`,`Automata`,`T/GPInfo`,`GoingPeriod`,`Escapement`,`CompensationPendulum`,`PendLgthIns`,`PendPeriod`,`WindingSystem`,`MaintainingPower`,`ElectricalClocks`,`Autowinder`,`Dials`,`DialMaterial`,`Hands`,`DialDate`,`OtherDialInfo`,`ClockCondition`,`SurveyDate`,`UpdateDate`,`RecorderCode`,`OtherInfo`,`DataEnter`,`TypeOfBuilding`,`OtherFeature`,`AutowindMake`,`SignificanceGrade`,`DataUpdateDate`,`PhotoContext`,`PhotoDial`,`PhotoTrainCount`,`Remontoire`,`Sources`,`History`,`CarillonWheels`,`GoingWheelSize`,`StrikeWheelSize`,`ChimeWheelSize`,`CarillonWheelSize`,`CarillonControl`,`WeightDrop`,`PulleyConfig`,`PendulumCorrection`,`PendCorDate`,`PullOffMethod`,`DialSize`,`DialIllumination`,`LeadOffDetail`,`RecordStatus`,`CofEChurchCode`,`MakerSerialNo`,`LatLong`,`GoingDrumSize`,`StrikeDrumSize`,`ChimeDrumSize`,`CarillonDrumSize`,`StrikeType`,`ChimeType`,`ChimeTime`,`ExtractNo`,`FinialType`,`FinialPosition`,`DatePeriod`,`BPM`,`BPH`, dadabik_revision_username, dadabik_revision_date_time, dadabik_revision_operation) SELECT `RefNo`,`UniqueNumberID`,`FormNo`,`Town`,`County`,`BuildingName`,`Dedication`,`Address`,`PostCode`,`LocationinBuilding`,`GridRef`,`PreviousLocation`,`PhotoClock`,`OtherLiterature`,`Comments`,`MakerSurname`,`MakerForename`,`MakerTown`,`DateonClock`,`DateCirca`,`Inscription`,`FrameType`,`FrameLength`,`FrameHeight`,`FrameDepth`,`FrameMaterial`,`GoingType`,`GoingTrainWheels`,`StrikingTrainWheels`,`ChimingTrainWheels`,`StrikeControl`,`TuneBarrel`,`Automata`,`T/GPInfo`,`GoingPeriod`,`Escapement`,`CompensationPendulum`,`PendLgthIns`,`PendPeriod`,`WindingSystem`,`MaintainingPower`,`ElectricalClocks`,`Autowinder`,`Dials`,`DialMaterial`,`Hands`,`DialDate`,`OtherDialInfo`,`ClockCondition`,`SurveyDate`,`UpdateDate`,`RecorderCode`,`OtherInfo`,`DataEnter`,`TypeOfBuilding`,`OtherFeature`,`AutowindMake`,`SignificanceGrade`,`DataUpdateDate`,`PhotoContext`,`PhotoDial`,`PhotoTrainCount`,`Remontoire`,`Sources`,`History`,`CarillonWheels`,`GoingWheelSize`,`StrikeWheelSize`,`ChimeWheelSize`,`CarillonWheelSize`,`CarillonControl`,`WeightDrop`,`PulleyConfig`,`PendulumCorrection`,`PendCorDate`,`PullOffMethod`,`DialSize`,`DialIllumination`,`LeadOffDetail`,`RecordStatus`,`CofEChurchCode`,`MakerSerialNo`,`LatLong`,`GoingDrumSize`,`StrikeDrumSize`,`ChimeDrumSize`,`CarillonDrumSize`,`StrikeType`,`ChimeType`,`ChimeTime`,`ExtractNo`,`FinialType`,`FinialPosition`,`DatePeriod`,`BPM`,`BPH`, 'root', '2021-06-22 22:02:42', 'insert' FROM `ClockDataExpanded` WHERE `RefNo` = '7090'
The DBMS server said: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'RefNo' in 'field list'

The new field is setup ok in admin with permissions etc but i still get the error RefNo, which is the new field, is not in the field list.

Regards

Andy
 

AndyB

Member
Eugenio,

Please ignnore my last post, i just read the revisions section of the manual regarding inserting the new field into the revisions table as well and it now works ok.

Thanks for your help.

Andy
 

eugenio

Administrator
Staff member
Hello Stefan,
you said the upgrade.php causes a connection loss but I am not sure what you mean, if you didn't get any error during upgrade it's strange the database hasn't been updated with the new status field.

Best,
 
Top