Click here to Skip to main content
16,008,183 members
Home / Discussions / Database
   

Database

 
GeneralRe: How do i store an array of 500 in an db Pin
Colin Angus Mackay7-Feb-05 1:25
Colin Angus Mackay7-Feb-05 1:25 
Generalfirebird data engine Vs MSDE data engine Pin
ppp0016-Feb-05 22:09
ppp0016-Feb-05 22:09 
GeneralRe: firebird data engine Vs MSDE data engine Pin
Rob Graham7-Feb-05 3:12
Rob Graham7-Feb-05 3:12 
Generalmoney datatype Pin
jetset326-Feb-05 20:59
jetset326-Feb-05 20:59 
GeneralRe: money datatype Pin
Luis Alonso Ramos7-Feb-05 19:54
Luis Alonso Ramos7-Feb-05 19:54 
GeneralRe: money datatype Pin
jetset329-Feb-05 5:04
jetset329-Feb-05 5:04 
General.net compact framework / sql Pin
kofler6-Feb-05 4:40
kofler6-Feb-05 4:40 
Generalget byte[] from a database Pin
Sasuko6-Feb-05 1:45
Sasuko6-Feb-05 1:45 
I've saved an image (converting in byte[]) inside a field of my database, now i would read the database getting these bytes[] and convertering into the original image...
I use this code:

OleDbDataReader myReader;
....
.. instance myReader here...
....
myCommand.ExecuteReader();

MemoryStream myStream;
int buffersize = 300000; // doubt n°2 = but if my image is bigger of 300000 ???
Byte[] outbyte = new Byte[299999];
myStream = new MemoryStream(outbyte, 0, 300000, true);
myReader.GetBytes(5, 0, outbyte, 0, buffersize);
myStream.Flush(); // am i just deleting all bytes unused?
pictureBox1.Image = Image.FromStream(myStream);
myStream.Close();

but this code doesn't work, where do i wrong?

GeneralRe: get byte[] from a database Pin
Sasuko6-Feb-05 2:45
Sasuko6-Feb-05 2:45 
GeneralRe: get byte[] from a database Pin
David Salter6-Feb-05 7:22
David Salter6-Feb-05 7:22 
GeneralRe: get byte[] from a database Pin
Sasuko_8-Feb-05 20:56
sussSasuko_8-Feb-05 20:56 
QuestionHow do you do with .mdb? Pin
Anonymous5-Feb-05 1:32
Anonymous5-Feb-05 1:32 
AnswerRe: How do you do with .mdb? Pin
Yulianto.6-Feb-05 18:11
Yulianto.6-Feb-05 18:11 
QuestionASP .NET, MS SQL Server 2000 with Window XP SP2 <- does not work??? Pin
Thang T.4-Feb-05 22:46
Thang T.4-Feb-05 22:46 
AnswerRe: ASP .NET, MS SQL Server 2000 with Window XP SP2 <- does not work??? Pin
Hesham Amin4-Feb-05 23:05
Hesham Amin4-Feb-05 23:05 
GeneralRe: ASP .NET, MS SQL Server 2000 with Window XP SP2 <- does not work??? Pin
Thang T.5-Feb-05 0:32
Thang T.5-Feb-05 0:32 
GeneralSQL Server fills event log Pin
Hesham Amin4-Feb-05 20:00
Hesham Amin4-Feb-05 20:00 
GeneralRe: SQL Server fills event log Pin
Hesham Amin4-Feb-05 23:48
Hesham Amin4-Feb-05 23:48 
GeneralDifficult JOIN Pin
Luis Alonso Ramos4-Feb-05 15:24
Luis Alonso Ramos4-Feb-05 15:24 
GeneralRe: Difficult JOIN Pin
Yulianto.4-Feb-05 16:05
Yulianto.4-Feb-05 16:05 
GeneralRe: Difficult JOIN Pin
Luis Alonso Ramos4-Feb-05 19:18
Luis Alonso Ramos4-Feb-05 19:18 
GeneralRe: Difficult JOIN Pin
Mike Dimmick5-Feb-05 1:52
Mike Dimmick5-Feb-05 1:52 
GeneralRe: Difficult JOIN Pin
Luis Alonso Ramos5-Feb-05 6:41
Luis Alonso Ramos5-Feb-05 6:41 
GeneralRe: Difficult JOIN Pin
Mike Dimmick5-Feb-05 7:32
Mike Dimmick5-Feb-05 7:32 
GeneralRe: Difficult JOIN Pin
Luis Alonso Ramos5-Feb-05 8:13
Luis Alonso Ramos5-Feb-05 8:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.