Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

NativeError 2124 - Invalid TIMESTAMP

2 posts in Visual Basic Last posting was on 2005-07-27 17:09:55.0Z
ttoyne Posted on 2005-07-27 15:18:31.0Z
From: <ttoyne@bellsouth.net>
Newsgroups: advantage.visual_basic
Subject: NativeError 2124 - Invalid TIMESTAMP
Date: Wed, 27 Jul 2005 10:18:31 -0500
Lines: 22
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 68.222.5.76
Message-ID: <42e7a771@solutions.advantagedatabase.com>
X-Trace: 27 Jul 2005 09:25:37 -0700, 68.222.5.76
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!68.222.5.76
Xref: solutions.advantagedatabase.com Advantage.Visual_Basic:996
Article PK: 1137789

cmd1.CommandText = "Insert into mwtrn([Chart Number],[Procedure
Code]," & _
"Description,[Attending Provider],Amount,[Transaction Type]," & _
"[Document Number],[Date From]," & _
"[Date To],Units,[Insurance Category],[Date Modified]" & _
")VALUES(" & "'" & mChart & _
"','" & mProcCode & "','" & mDesc & "','" & mAtt & _
"'," & mAmtPay & ",'" & mTrantypePay & "','" & mDocNbr & "','" & _
mDatefrom & "','" & mDateto & "'," & mUnits & ",'" & mInsCat & _
"','" & Now() & "')"

The above insert statement works with the exception of NOW() for the
TIMESTAMP field. My understanding of the documentation is the Now() is a
valid value for a timestamp datatype.

What are the work arounds?

Thanks,

Tim


Joachim Duerr (ADS Support) Posted on 2005-07-27 17:09:55.0Z
From: "Joachim Duerr (ADS Support)" <jojo.duerr@gmx.de>
Subject: Re: NativeError 2124 - Invalid TIMESTAMP
Newsgroups: Advantage.Visual_Basic
References: <42e7a771@solutions.advantagedatabase.com>
Organization: Extended Systems GmbH
User-Agent: XanaNews/1.17.4.1
X-Face: ,QMv7[luB)BpWAQ~:"kw6n%0ieY63.:g2K3n~8ky0;||5Xle*Xq+=~<Fy:0CVC2nx@8~vZ
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
NNTP-Posting-Host: 195.2.185.25
Message-ID: <42e7b1d3@solutions.advantagedatabase.com>
Date: 27 Jul 2005 10:09:55 -0700
X-Trace: 27 Jul 2005 10:09:55 -0700, 195.2.185.25
Lines: 17
Path: solutions.advantagedatabase.com!solutions.advantagedatabase.com!195.2.185.25
Xref: solutions.advantagedatabase.com Advantage.Visual_Basic:997
Article PK: 1137791

<ttoyne@bellsouth.net> wrote in
<42e7a771@solutions.advantagedatabase.com> :

> The above insert statement works with the exception of NOW() for the
> TIMESTAMP field. My understanding of the documentation is the Now()
> is a valid value for a timestamp datatype.
>
> What are the work arounds?

remove the quotes around 'now()' since it produces a timestamp value,
but you try to insert the text 'now()' and you don't call the function
itself.

--
Joachim Duerr
EMEA Lead ADS Support, Extended Systems GmbH, Germany
advantage[AT]extendsys.de