L
L
lpinvie2019-02-08 14:21:45
PostgreSQL
lpinvie, 2019-02-08 14:21:45

How to read BLOB from PostgreSQL in C#?

The table stores data in BLOB, how to read it correctly in c#? And determine their type (numbers, strings or picture). I am using Npgsql.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Roman Mirilaczvili, 2019-04-15
@2ord

BLOB is just an array of bytes. The content type must be known and determined in advance.
To read a BLOB, you can use a MemoryStream.
https://docs.microsoft.com/ru-ru/dotnet/api/system...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question