1

If I got to calendar, click on To Do, then try to add an event, the form pops up, I fill it out, press save, but no Event gets added. In the SQL error log's I see an error like this:

2011-09-29 14:57:07 EDT ERROR:  null value in column "visibility" violates not-null constraint
2011-09-29 14:57:07 EDT STATEMENT:  insert into
vtiger_activity(activityid,subject,date_start,time_start,time_end,due_date,status,eventstatus,priority,sendnotification,activitytype,visibility,duration_hours,duration_minutes,location,recurringtype,notime) 
values('235','Testing','2011-09-29','19:50',NULL,'2011-09-29','Not Started',NULL,'High','0','Task',NULL,NULL,NULL,NULL,NULL,'0')

So, for some reason, it is trying to add a To-Do while inserting null values. My biggest problem is that I cannot locate the origin of the query. So, basically, the most important thing I am asking is what file takes the data that was input into the todosave form and turns it into a query.

I don't know if many people on here use Vtiger, but I couldn't figure this out so I went ahead and posted anyway. The official documentation is not very helpful in my opinion.

Thanks for everything, have a good day.

zermy
  • 611
  • 1
  • 11
  • 25

1 Answers1

1

This might be an isolated case, but was any of the modules modified recently? In this case, I would assume that it would be the Calendar module. I've tested this on the demo website and on my vTiger installation and it works fine..

Perhaps you can download a fresh copy of vTiger and replace the modules/Calendar all its content.

By the way, another place to ask if you have any questions, is the vTiger forums.

http://forums.vtiger.com/index.php

Usually you can ask it in the Help - 5.2.1 section. Hope this helps!

Shiroi98
  • 842
  • 1
  • 9
  • 13
  • I am so sorry for the late response. Thanks for the reply. I figured out the problem, and yeah it mostly is an isolated case. The thing is, I changed my vtiger from MySQL to PostgreSQL. One of the big differences between the two DB's is that MySQL treats an empty entry as empty while PostgreSQL treats it as null. So, in order to fix it, I added: `$focus->column_fields["visibility"] = 'Private'` to TodoSave.php around line 64. – zermy Nov 23 '11 at 16:28