I use 64bit integers quite a lot and am running into problems. I am trying to execute this query :-
The result is :-INSERT INTO logon (id, staff_id, username, pcid, pcname) VALUES
(1090307192896810146,1823700001955521506,'smith','46173199','alpha');
But "1823700001955521506" is a perfectly valid int64 value, and I can execute this SQL statement using PgAdmin quite happily.CoreLab.PostgreSql.PgSqlException was unhandled by user code
Message="value \"1823700001955521506\" is out of range for type integer"
Source="mscorlib"
ErrorCode=-2147467259
CallStack="PL/pgSQL function \"before_post_record\" line 4 at assignment"
DetailMessage=""
FileName="numutils.c"
Hint=""
LineNumber=77
Position=0
ProcedureName="pg_atoi"
StackTrace:
Server stack trace:
at CoreLab.PostgreSql.PgSqlCommand.a(CommandBehavior A_0, IDisposable A_1, Int32 A_2, Int32 A_3)
at CoreLab.Common.DbCommandBase.c(CommandBehavior A_0)
at CoreLab.Common.DbCommandBase.ExecuteNonQuery()
at CoreLab.Common.DbCommandBase.a(CommandBehavior A_0)
at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, Object[]& outArgs)...
Here is the SQL to create the table in question so that you can try it for yourself :-
Please help!CREATE TABLE logon
(
id bigint NOT NULL,
staff_id bigint NOT NULL,
username character varying(50) NOT NULL,
pcid character varying(50) NOT NULL,
pcname character varying(50),
ipaddress character varying(50),
query boolean,
CONSTRAINT logon_pkey PRIMARY KEY (id)
) WITHOUT OIDS;