Solved

mysql CONVERT_TZ null centos

Posted on 2014-09-28
5
170 Views
Last Modified: 2014-11-22
I have a programmer who is using CONVERT_TZ in his code for a reports template using nvd3.
He tells me that there is a problem which is 'CONVERT_TZ null' on a centos box that we are working on.

I looked for a solution and found;
mysql_tzinfo_to_sql /usr/share/zoneinfo | mysql -u root -p mysql

However, this doesn't seem to work or it only works now and then and sometimes only on one server, not the other, yet they are both Centos 6.x using pretty much the same setup.

My question is.... does the programmer HAVE to use this or is there another way to achieve what ever he is trying to do?

Secondly, instead of or aside from the command above to fix the problem, is there something installed on one server which might not be installed on the other? I would much rather simply install what ever is missing over having to run mysql commands to fix the problem.
0
Comment
Question by:projects
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 110

Accepted Solution

by:
Ray Paseur earned 250 total points
ID: 40348680
...another way to achieve what ever he is trying to do?
Would help to have an explanation of what he's trying to do. CONVERT_TZ returns null when the arguments are invalid.
http://dev.mysql.com/doc/refman/5.5/en/date-and-time-functions.html#function_convert-tz
...something installed on one server which might not be installed on the other?
Unfortunately, there are a huge number of configuration options and variables.  Fortunately they are all documented online.
http://dev.mysql.com/doc/refman/5.7/en/server-configuration-defaults.html
http://dev.mysql.com/doc/refman/5.7/en/server-options.html
http://dev.mysql.com/doc/refman/5.7/en/server-system-variables.html
0
 

Author Comment

by:projects
ID: 40348695
As far as I can tell, the only difference in terms of what's installed would be the time zone files which are installed by default anyhow.

Since this question isn't helpful as it is, I will try to get more info from him. His reply to me at this moment is very ambiguous so I'll get more info and update.
0
 
LVL 58

Assisted Solution

by:Gary
Gary earned 250 total points
ID: 40349074
Just to be sure in the /usr/share/zoneinfo directory do you have the timezone files and nothing else?
0
 

Author Comment

by:projects
ID: 40351028
Not sure what nothing else means but yes, both servers seem to have their zone files and nothing else that I can see.
0
 

Author Comment

by:projects
ID: 40397376
The programmer is gone and I have no way of knowing why he needed or used this. I will need to ask the next programmer to find out why and change this so it is not needed.

Not sure how to close this now useless question.
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Build an array called $myWeek which will hold the array elements Today, Yesterday and then builds up the rest of the week by the name of the day going back 1 week.   (CODE) (CODE) Then you just need to pass your date to the function. If i…
This article shows the steps required to install WordPress on Azure. Web Apps, Mobile Apps, API Apps, or Functions, in Azure all these run in an App Service plan. WordPress is no exception and requires an App Service Plan and Database to install
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

691 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question