Ask a Question related to IBM DB2, Design and Development.
-
sea #1
convert visual basic "string" data type to DB2 "blob"
Does anyone know if a visual basic string data type can be converted
to DB2 blob datatype?
I have all data in XML files and I use Visual Basic to read the
characters from the XML file and insert into the DB2 database. For
most common datatypes, the conversion from VB to DB2 is easy, example,
CInt to convert VB string to integer, CDbl to convert VB string to
double, etc.
But is there a way to convert from VB string to insert to a BLOB
(binary large object data type) field in DB2?
Thank you very much!
sea Guest
-
Distiller uses Finder creator/type "ORAC"/" FDP"
Distiller 8/9 running on Intel based mac running OSX 10.4.11/10.5.5. It seems that Distiller creates pdf-files with creator/type "ORAC"/" FDP".... -
CFINPUT type="radio" w/ "value" requires "label"
On a Flash form, when you specify type='radio' and value='whatever', the value of the 'value' attribute will be displayed as a label if no 'label'... -
"Error Creating Control" and "Cast from String"
I'm creating a custom date control. In appearance, it's just a textbox and a button. It has three custom properties: CalDate, CalDateType and... -
#26292 [Opn->Bgs]: substr returns "0" for any offset on the string "0"
ID: 26292 Updated by: sniper@php.net Reported By: ravacholp at hotmail dot com -Status: Open +Status: ... -
#25366 [NEW]: form buttons of type "image" dont send "submit" $_POST variable in IE
From: jordanolsommer at imap dot cc Operating system: Windows XP PHP version: 4.3.2 PHP Bug Type: Variables related Bug... -
Mark Yudkin #2
Re: convert visual basic "string" data type to DB2 "blob"
VB string is automatically converted to CLOB when necessary, but you need to
remember that a VB string is UCS-2 Unicode, whereas CLOB is 8-byte
character. To convert to BLOB you'll need to turn the VB string into a
byte(). This will depend upon whether you're using the string to hold raw
dataas is, or whether you've expanded each byte to two bytes because you're
atually storing ASCII in Unicode strings. You may also need to consider
whether your input is not Unicode to start with (you said XML). Review the
VB StrConv BIF for details.
Since you're starting with XML, which is character data, I would strongly
recommend your using a CLOB rather than a BLOB field.
Finally, Bruce McKinney's VBCore provides an amazing component, with
complete VB source code for a mass of useful tasks, including various
routines for handling all sorts of binary conversions. See
[url]http://archive.devx.com/upload/free/features/vbpj/1999/mckinney/mckinney2a.asp[/url].
The book that describes the code can be bought used from Amazon and is
highly recommended (especially if you need help understanding the vbcore
code).
"sea" <sea_099@hotmail.com> wrote in message
news:f8c6e337.0307181415.39139d95@posting.google.c om...> Does anyone know if a visual basic string data type can be converted
> to DB2 blob datatype?
>
> I have all data in XML files and I use Visual Basic to read the
> characters from the XML file and insert into the DB2 database. For
> most common datatypes, the conversion from VB to DB2 is easy, example,
> CInt to convert VB string to integer, CDbl to convert VB string to
> double, etc.
>
> But is there a way to convert from VB string to insert to a BLOB
> (binary large object data type) field in DB2?
>
> Thank you very much!
Mark Yudkin Guest



Reply With Quote

