I don't see the cast function listed in the Core Functions section of the web page...
BTW, what is the concatenation operator? -----Original Message----- From: Dennis Cote [mailto:[EMAIL PROTECTED] Sent: Wednesday, January 31, 2007 5:21 PM To: [email protected] Subject: Re: [sqlite] Equivalent syntax? Anderson, James H (IT) wrote: > What's the equivalent sqlite syntax for sybase convert function? For > example, > > select distinct > date, CDId, CDName, CDTicket, > tradeId, tapsAccount, CDBook, coalesce(CDFid,'') CDFid, > CDStatus, CDTradeDate, CDExpDate, CDNotional, > CDCurr, CDSellBuy, CDType, CDExerType, > CDEntity, CDCusip, CDSetlType, CDCredInit, > CDSingleEntry, CDMaterialType, CDEffDate, CDPremFreq, > CDPaymentType, CDUpfrontSetl, CDPublicInfo, CDCollReq, > CDSpreadCurve, CDPremium, CDOptType, CDAccrue, > CDRefPrice, CDPremiumAmnt, CDLastCoupLength, CDWhoDelivers, > CDCollateralText, CDFactorReason, CDDefStartProt, CDDefEndProt, > CDDefProtType, > convert(char(80), NULL) CDComment, > convert(varchar(100), NULL) CDEvent, > convert(char(11), NULL) CDCurveType, > convert(char(11), NULL) CrvShName, > convert(varchar(90), NULL) CDRefEntity, > convert(char(3), NULL) CDRefIndustry, > convert(char(3), NULL) CDRefCountry, > convert(char(4), NULL) CDRefSNP, > convert(char(4),NULL) CDRefMoody, > convert(char(4),NULL) CDRefMSRating, > CDRefId > into TMP_credDerivOrig > from credDerivOrig_C1 > > Based on context I would say the cast function is the rough equivalent. But, since all text types in SQLite are equivalent there is no need to convert them from one type to another (i.e. from varchar(100) to char(80)). I suspect this query would translate to SQLite by simply removing the convert(...) clauses. HTH Dennis Cote ------------------------------------------------------------------------ ----- To unsubscribe, send email to [EMAIL PROTECTED] ------------------------------------------------------------------------ ----- -------------------------------------------------------- NOTICE: If received in error, please destroy and notify sender. Sender does not intend to waive confidentiality or privilege. Use of this email is prohibited when received in error. ----------------------------------------------------------------------------- To unsubscribe, send email to [EMAIL PROTECTED] -----------------------------------------------------------------------------

