|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Data (column) conversion issue on SQL select |
« View previous topic :: View next topic » |
Author |
Message
|
schroederms |
Posted: Wed Jul 09, 2008 12:10 pm Post subject: Data (column) conversion issue on SQL select |
|
|
 Disciple
Joined: 21 Jul 2003 Posts: 169 Location: IA
|
I'm simply building a string and doing a passthru, what is happening is in this case PartnerID is a uniqueIdentifier (SQL Server) and the SQL finds the row just fine, but when it populates my result set, the PartnerID looks as though it is a hex value and the dashed are gone. I'm runninng the broker on AIX as well.
Any ideas?
Thanks.
Input string and result below.
(0x03000000):SQL1 = 'SELECT dbo.Partner.PartnerID, dbo.Partner.FirstName,
dbo.Partner.LastName, dbo.Partner.MiddleName, dbo.Partner.PreferredName,
dbo.Partner.BusinessName, dbo.Partner.LanguageId,
dbo.Prefix.Name AS Prefix, dbo.Suffix.Name AS Suffix, dbo.Partner.PartnerId
FROM dbo.Partner LEFT OUTER JOIN
dbo.Suffix ON dbo.Partner.SuffixId = dbo.Suffix.SuffixId LEFT OUTER JOIN
dbo.Prefix ON dbo.Partner.PrefixId = dbo.Prefix.PrefixId INNER JOIN
dbo.PartnerStatus ON dbo.Partner.PartnerStatusId = dbo.PartnerStatus.PartnerStatusId
WHERE (dbo.Partner.PartnerStatusId = 1) AND dbo.Partner.PartnerId in ('cc3812c3-fcd7-4fed-9171-3bded8f3cec4')'
(
(0x01000000):RESULT = (
(0x03000000):PartnerID = X'cc3812c3fcd74fed91713bded8f3cec4'
(0x03000000):FirstName = 'Lucas'
(0x03000000):LastName = 'Carder'
(0x03000000):MiddleName = 'D'
(0x03000000):PreferredName = 'Luke'
(0x03000000):BusinessName = NULL
(0x03000000):LanguageId = 1
(0x03000000):Prefix = 'Dr.'
(0x03000000):Suffix = 'II'
(0x03000000):PartnerId = X'cc3812c3fcd74fed91713bded8f3cec4'
) |
|
Back to top |
|
 |
sridhsri |
Posted: Wed Jul 09, 2008 12:48 pm Post subject: |
|
|
Master
Joined: 19 Jun 2008 Posts: 297
|
What is the column data type in the table ? |
|
Back to top |
|
 |
schroederms |
Posted: Wed Jul 09, 2008 1:07 pm Post subject: |
|
|
 Disciple
Joined: 21 Jul 2003 Posts: 169 Location: IA
|
sorry, I thought I had it in it. The column is defined as a "uniqueidentifier" |
|
Back to top |
|
 |
sridhsri |
Posted: Wed Jul 09, 2008 1:17 pm Post subject: |
|
|
Master
Joined: 19 Jun 2008 Posts: 297
|
Message Broker help (http://publib.boulder.ibm.com/infocenter/wmbhelp/v6r0m0/index.jsp?topic=/com.ibm.etools.mft.doc/ak20708_.htm) says that it will be returned as a BLOB. So I am guessing what you are seeing is "as-designed".
I would suggest that before you select on the uniqueid, you convert it to a BLOB and then search it. In the result set, you convert the BLOB back to CHAR. Perhaps that will solve it. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|