From: Seader, Cameron <CSeader@idahopower.com>
To: pgsql-php@postgresql.org
Subject: int8 and PHP problems
Date: Fri, 19 Dec 2003 07:42:55 -0700
Message-ID: <71B8A8BEC516CF46835CA629156CF21163F6CA@bedford.idacorp.local> (raw)
I have a database with two int8 fields that don't seem to be working properly. I want it too be able to store the values of 0x000000000002, but it won't. MySQL seems too. Strange. PHP does not handle 64 bit integers so that will not work either. How can i deal with this kind of value useing PHP and PostgreSQL.
One Reply i had made sense, but not sure how to do it.
You are apparently trying to insert a hex string "0x000000000002"
>(notice it starts with '0x') into an int8 field -- don't do that.
>Convert the hex to integer before inserting, or cast it, like so:
>regression=# select x'000000000002'::int8;
How do you do the above casting as explained before inserting, or how do you convert it to an integer when PHP will not handle the 64 bit integers at all.
Can someone please help on this?
Thanks,
Cameron Seader
Operations Center Technician II
CSeader@Idahopower.com
1.208.388.2582 Office
[INFO] -- Access Manager:
This transmission may contain information that is privileged, confidential and/or exempt from disclosure under applicable law. If you are not the intended recipient, you are hereby notified that any disclosure, copying, distribution, or use of the information contained herein (including any reliance thereon) is STRICTLY PROHIBITED. If you received this transmission in error, please immediately contact the sender and destroy the material in its entirety, whether in electronic or hard copy format. Thank you. A2
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-php@postgresql.org
Cc: CSeader@idahopower.com
Subject: Re: int8 and PHP problems
In-Reply-To: <71B8A8BEC516CF46835CA629156CF21163F6CA@bedford.idacorp.local>
References: <71B8A8BEC516CF46835CA629156CF21163F6CA@bedford.idacorp.local>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox