Hi,

I have tried this without being able to control it:
ARDATE="%Y;%m;%d %H;%M;%S"
ARDATEONLY="yyyy;MM;dd"
ARTIMEONLY="HH;MM;ss"
export ARDATE
export ARDATEONLY
export ARTIMEONLY

I can supply "2016-01-31 ..." and "2016.01.31 ..." and these both works. If I 
use "/" it seems to interpret it in another order so the year is wrong.

As for the time portion I can get "23.59.59" to work, but "23:59:59" does not 
work. The faulty one does not give an error but seems to default to "00:00:00".

So there seems to be some "smart" things going on trying different formats 
before giving up.

Specifying the ";" delimiter after setting the above variables does not work at 
all.

The program I am using is the {serverinstall}/artools/arexport.sh script in 
9.1.0 where you can specify a -q option to do a qualification.

Best Regards - Misi, RRR AB, http://www.rrr.se (http://www.rrr.se) (ARSList MVP 
2011)

Ask the Remedy Licensing Experts (Best R.O.I. Award at WWRUG10/11/12/13)
* RRR|License - Not enough Remedy licenses? Save money by optimizing.
* RRR|Log - Performance issues or elusive bugs? Analyze your Remedy logs
Find these products, and many free tools and utilities, at http://rrr.se 
(http://rrr.se)
December 13, 2017 6:01 PM, "Grooms, Frederick W"  wrote:
        What if you do set ARDATE? 
        From: ARSList [mailto:[email protected] 
(mailto:mailto:[email protected])] On Behalf Of Misi Mladoniczky
Sent: Wednesday, December 13, 2017 10:46 AM
To: ARSList 
Subject: Re: Date format in Java API search criteria 
        Hi,

Well, on my Ubuntu-machine it apparently defaults to the Swedish format 
"YYYY-MM-DD HH:mm:ss". One of my clients using that same program are 
successfully using the format "M/D/YYYY h:mm:ss a"...

I tried changing my LANG environment variable without success. It seems to pick 
up some other system setting.

My standard setting:
locale
LANG=sv_SE.UTF-8
LANGUAGE=sv
LC_CTYPE="sv_SE.UTF-8"
LC_NUMERIC=sv_SE.UTF-8
LC_TIME=sv_SE.UTF-8
LC_COLLATE="sv_SE.UTF-8"
LC_MONETARY=sv_SE.UTF-8
LC_MESSAGES="sv_SE.UTF-8"
LC_PAPER=sv_SE.UTF-8
LC_NAME=sv_SE.UTF-8
LC_ADDRESS=sv_SE.UTF-8
LC_TELEPHONE=sv_SE.UTF-8
LC_MEASUREMENT=sv_SE.UTF-8
LC_IDENTIFICATION=sv_SE.UTF-8
LC_ALL=

I reset LC_ALL and get this, but the parseQualification still uses the same 
YYYY-MM-DD format:
locale
LANG=en_US.UTF-8
LANGUAGE=sv
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=en_US.UTF-8

Best Regards - Misi, RRR AB, http://www.rrr.se (http://www.rrr.se) (ARSList MVP 
2011)

Ask the Remedy Licensing Experts (Best R.O.I. Award at WWRUG10/11/12/13)
* RRR|License - Not enough Remedy licenses? Save money by optimizing.
* RRR|Log - Performance issues or elusive bugs? Analyze your Remedy logs
Find these products, and many free tools and utilities, at  http://rrr.se 
(http://rrr.se)
December 13, 2017 5:29 PM, "LJ LongWing"  wrote: 
        ok....that's a very good question that I've never had to 
explore.....the API defaults to MM-DD-YYYY HH:MM:SS type of format....which is 
standard in America (and just about nowhere else)....I've never had to deal 
with date/time formatting in the Java API....so sorry, I don't have a ready 
answer for you :| 
        On Wed, Dec 13, 2017 at 9:15 AM, Misi Mladoniczky  wrote:  
        Hi,

You sort of understood.

It concerns controlling the date+time format when the Java-API program is 
calling the parseQualification method.

In a C-API program, you just set the environment variable ARDATE before running 
it, and it will use the specified format.

So how can you control this before running a Java-API program?

Best Regards - Misi, RRR AB, http://www.rrr.se (http://www.rrr.se) (ARSList MVP 
2011)

Ask the Remedy Licensing Experts (Best R.O.I. Award at WWRUG10/11/12/13)
* RRR|License - Not enough Remedy licenses? Save money by optimizing.
* RRR|Log - Performance issues or elusive bugs? Analyze your Remedy logs
Find these products, and many free tools and utilities, at  http://rrr.se 
(http://rrr.se)
        December 13, 2017 5:11 PM, "LJ LongWing"  wrote: 
        I'm sorry Misi, I'm not sure I understand your inquiry...are you asking 
how do you tell the Java api that when using the parseQualification method what 
format a date, included in that string is? 
        On Wed, Dec 13, 2017 at 9:04 AM, Misi Mladoniczky  wrote:  
        Hi,

How do you control which date format is used by a client Java ARAPI program 
when parsing the qualifier string before q query?

In the C-API you would set environment ARDATE="%Y-%m-%d %H:%M:%S" or similar.

Best Regards - Misi, RRR AB, http://www.rrr.se (http://www.rrr.se) (ARSList MVP 
2011)

Ask the Remedy Licensing Experts (Best R.O.I. Award at WWRUG10/11/12/13)
* RRR|License - Not enough Remedy licenses? Save money by optimizing.
* RRR|Log - Performance issues or elusive bugs? Analyze your Remedy logs
Find these products, and many free tools and utilities, at  http://rrr.se 
(http://rrr.se)  
--
ARSList mailing list
[email protected] (mailto:[email protected])
https://mailman.rrr.se/cgi/listinfo/arslist 
(https://mailman.rrr.se/cgi/listinfo/arslist)       
--
ARSList mailing list
[email protected] (mailto:[email protected])
https://mailman.rrr.se/cgi/listinfo/arslist 
(https://mailman.rrr.se/cgi/listinfo/arslist)
-- 
ARSList mailing list
[email protected]
https://mailman.rrr.se/cgi/listinfo/arslist

Reply via email to