@@ -0,0 +1,2787 @@
+/**%0A * END USER LICENSE AGREEMENT (%E2%80%9CEULA%E2%80%9D)%0A *%0A * READ THIS AGREEMENT CAREFULLY (date: 9/13/2011):%0A * http://www.akiban.com/licensing/20110913%0A *%0A * BY INSTALLING OR USING ALL OR ANY PORTION OF THE SOFTWARE, YOU ARE ACCEPTING%0A * ALL OF THE TERMS AND CONDITIONS OF THIS AGREEMENT. YOU AGREE THAT THIS%0A * AGREEMENT IS ENFORCEABLE LIKE ANY WRITTEN AGREEMENT SIGNED BY YOU.%0A *%0A * IF YOU HAVE PAID A LICENSE FEE FOR USE OF THE SOFTWARE AND DO NOT AGREE TO%0A * THESE TERMS, YOU MAY RETURN THE SOFTWARE FOR A FULL REFUND PROVIDED YOU (A)%0A * DO NOT USE THE SOFTWARE AND (B) RETURN THE SOFTWARE WITHIN THIRTY (30) DAYS%0A * OF YOUR INITIAL PURCHASE.%0A *%0A * IF YOU WISH TO USE THE SOFTWARE AS AN EMPLOYEE, CONTRACTOR, OR AGENT OF A%0A * CORPORATION, PARTNERSHIP OR SIMILAR ENTITY, THEN YOU MUST BE AUTHORIZED TO%0A * SIGN FOR AND BIND THE ENTITY IN ORDER TO ACCEPT THE TERMS OF THIS AGREEMENT.%0A * THE LICENSES GRANTED UNDER THIS AGREEMENT ARE EXPRESSLY CONDITIONED UPON%0A * ACCEPTANCE BY SUCH AUTHORIZED PERSONNEL.%0A *%0A * IF YOU HAVE ENTERED INTO A SEPARATE WRITTEN LICENSE AGREEMENT WITH AKIBAN FOR%0A * USE OF THE SOFTWARE, THE TERMS AND CONDITIONS OF SUCH OTHER AGREEMENT SHALL%0A * PREVAIL OVER ANY CONFLICTING TERMS OR CONDITIONS IN THIS AGREEMENT.%0A */%0Apackage com.akiban.server.types3.mcompat.mfuncs;%0A%0Aimport com.akiban.server.types3.*;%0Aimport com.akiban.server.types3.mcompat.mtypes.MDatetimes;%0Aimport com.akiban.server.types3.mcompat.mtypes.MNumeric;%0Aimport com.akiban.server.types3.pvalue.PValueSource;%0Aimport com.akiban.server.types3.pvalue.PValueTarget;%0Aimport com.akiban.server.types3.texpressions.TInputSetBuilder;%0Aimport com.akiban.server.types3.texpressions.TOverloadBase;%0A%0Apublic class MMaketime extends TOverloadBase %7B%0A%0A    @Override%0A    protected void buildInputSets(TInputSetBuilder builder) %7B%0A        builder.covers(MNumeric.BIGINT, 0, 1, 2);%0A    %7D%0A%0A    @Override%0A    protected void doEvaluate(TExecutionContext context, LazyList%3C? extends PValueSource%3E inputs, PValueTarget output) %7B%0A        // Time input format HHMMSS%0A        long hours = inputs.get(0).getInt64(); %0A        long minutes = inputs.get(1).getInt64();%0A        long seconds = inputs.get(2).getInt64();%0A        %0A        // Check for valid input%0A        if (minutes %3E= 60 %7C%7C minutes %3C 0) %7B%0A            output.putNull();%0A            return;%0A        %7D%0A        if (seconds %3E= 60 %7C%7C seconds %3C 0) %7B%0A            output.putNull();%0A            return;%0A        %7D%0A        %0A        long time = hours %3C 0 ? -1 : 1;%0A        hours *= time;%0A        time *= seconds + minutes * 100 + hours * 10000;%0A        output.putObject(time);     %0A    %7D%0A%0A    @Override%0A    public String overloadName() %7B%0A        return %22MAKETIME%22;%0A    %7D%0A%0A    @Override%0A    public TOverloadResult resultType() %7B%0A        return TOverloadResult.fixed(MDatetimes.TIME);%0A    %7D%0A%7D%0A

Add MAKETIME