Search Postgresql Archives

ADO.NET ExecuteReader returns no rows

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

Someitmes ExectueReader doesn't return rows, if I repeat the method it
does!!

I've got code like that:
            using (NpgsqlDataReader readFrames =
command.ExecuteReader())
            {
                if (!readFrames.HasRows)
                {
                    System.Diagnostics.Debugger.Break();
                }

                while (readFrames.Read())
                {
                    currentMaxDate =
(DateTime)readFrames["idvideodate"];
                    mediaData.Add((byte[])readFrames["mediabinary"]);
                }

                readFrames.Close();
            }

That part of code executes multiple times and always, soon or later
I've got reader without rows.. When I execute that statement again:
the same parameters - ExecuteReader() returns rows (as it should).

The problem occurs in both versions: 0.71 and in 1.0 beta 2.
I've also tried commercial driver from Core Lab.. with the same
result.
PostgresSQL version 8.1.2.

The field idvideodate is Timestamp and mediabinary is bytea.

Probably it's  a problem not with ado.net driver, but with
PostgressSQL but how to cope with that?

Roman.



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux