× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I am using imbedded SQL to extract a data set. I am having a terrible time
figuring out how to coalesce a timestamp or even a time.

I started with the timestamp and had no luck. I split the field into a date
and time. Now, the date works but the time does not.

I am doing a Left Outer Join and may not get Records. I keep getting the
same error message - chop the 01.01.00 to 01.01 but no luck.

When I search I only get DATE. I cannot find examples to TimeStamp or Time.



(Run SQL Scripts)

Select A.TANUM, A.TACONT, A.TAMODL, A.TATYPE , A.TAORGD, A.TAOQTY, A.TAORDL,
A.TAVEND, A.TAORDN,

A.TASAMP, A.TARETN, A.TABRCH, B.TDUOM, B.TDGTIN,

B.TDLENG, B.TDWIDT, B.TDHEIG, B.TDWEIG, B.TDQUAN,

B.TDESTF, C.SKDESC, C.SKUPC, C.SKUM, C.SKMOQT,

C.SKLTLO,

COALESCE(D.IQCCHGDT,DATE(1990-01-01)),

COALESCE(D.IQCCHGTM,TIME(01.01.00)),

COALESCE(D.IQCSTAT,' ')

From TWINDEV.TPLATRD AS A

Join TWINDEV.TPLDIM AS B ON A.TAMODL = B.TDMODL

Join TWINDEV.TPLSKU AS C ON A.TAMODL = C.SKMODL

Left Outer Join JOHDICLIB.TPLIQC AS D ON A.TANUM = D.IQCNUM
AND A.TACONT = IQCCONT ;





Message: [SQL0104] Token .00 was not valid. Valid tokens: ) ,. Cause . . . .
. : A syntax error was detected at token .00.

Token .00 is not a valid token. A partial list of valid tokens is ) ,.

This list assumes that the statement is correct up to the token



D.J.


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.