Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

Re: SOT: DBI::ODBC datetime format for update: msg#00064

db.tds.freetds

Subject: Re: SOT: DBI::ODBC datetime format for update

Il mer, 2004-09-15 alle 20:03, Roderick A. Anderson ha scritto:
> Sorry for the off topic post but my web searches have not produced an
> answer. In fact I'm not necessarily looking for an answer but a pointer
> (or a whack from a clue-stick) to where to look or the correct terms to
> use for my search. I have tried all the obvious terms in various
> collections and combinations and only found information on how to change
> the output of datetime fields.
>
> I'm getting a failure message using DBI::ODBC on a Win2k server
> accessing a SQL Server database (different system) via a system dsn. I
> can't figure out what format to use for a datetime field. I've not had
> a problem doing similar operation using Win32::ODBC with a smalldatetime
> field. But when using DBI::ODBC and updating a datatime field I get
> errors like this:
>
> DBI Error:DBD::ODBC::st execute failed: [Microsoft][ODBC SQL Server
> Driver] Invalid character value for cast specification (SQL-22018)(DBD:
> st_execute/SQLExecute err=-1) at script.pl line 77.
>
> The variable used is set to '09/15/04' but even attempts using '20040915
> 05:05:05' and variations fail.
>
> This goes away when I remove the code to update the datetime field.
>
> So where should I go or what should I search for?
>

Try ISO format like '2004-09-15 05:05:05'. There is also an ODBC syntax
{ts 2004-09-15 05:05:05} that should be supported by all ODBC drivers.

freddy77


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
hardware.arm.at...    cms.citadel.dev...    video.gstreamer...    java.facelets.u...    misc.basics.qna...    web.wiki.instik...    network.uip.use...    xdg.devel/2003-...    tex.bibtex.bibd...    finance.quotesp...    ietf.zeroconf/2...    redhat.blinux.g...    suse.db2/2003-0...    php.phpesp/2004...    uml.devel/2003-...    gnome.labyrinth...    qnx.openqnx.dev...    boot-loaders.gr...    db.dataperfect....    audio.audacity....    linux.uclinux.m...    editors.j.devel...    os.openbsd.tech...    kde.users.multi...   
Home | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation