<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: store uniqueidentifier - primary key in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848037#M4878880</link>
    <description>&lt;P&gt;Sorry, I don't use UltraLite/UltraLiteJ so my chance to help is quite delimited...&lt;/P&gt;
&lt;P&gt;What error (SQLCODE) are you getting?&lt;/P&gt;
&lt;P&gt;Do you use an &lt;STRONG&gt;UUIDValue type&lt;/STRONG&gt; or a string or byte[] to store the UUID?&lt;/P&gt;
&lt;P&gt;You might try to use a prepared statement, here with a UUID string, such as (untested!):&lt;/P&gt;
&lt;DIV class="codehilite"&gt;&lt;PRE&gt;&lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;Create&lt;/SPAN&gt; &lt;SPAN class="n"&gt;a&lt;/SPAN&gt; &lt;SPAN class="k"&gt;new&lt;/SPAN&gt; &lt;SPAN class="n"&gt;PreparedStatement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;object&lt;/SPAN&gt; &lt;SPAN class="n"&gt;from&lt;/SPAN&gt; &lt;SPAN class="n"&gt;an&lt;/SPAN&gt; &lt;SPAN class="n"&gt;existing&lt;/SPAN&gt; &lt;SPAN class="n"&gt;connection&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;String&lt;/SPAN&gt; &lt;SPAN class="n"&gt;sql_string&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="s"&gt;"SELECT * FROM myTable WHERE pk = ?"&lt;/SPAN&gt;&lt;SPAN class="p"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;PreparedStatement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ps&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;conn&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;prepareStatement&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;sql_string&lt;/SPAN&gt;&lt;SPAN class="p"&gt;);&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;set&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="mi"&gt;1&lt;/SPAN&gt;&lt;SPAN class="p"&gt;,&lt;/SPAN&gt; &lt;SPAN class="s"&gt;'5ad8bc00-2822-433f-88d1-2dd028e70b17'&lt;/SPAN&gt;&lt;SPAN class="p"&gt;);&lt;/SPAN&gt;

&lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;result&lt;/SPAN&gt; &lt;SPAN class="n"&gt;returns&lt;/SPAN&gt; &lt;SPAN class="n"&gt;true&lt;/SPAN&gt; &lt;SPAN class="k"&gt;if&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;execute&lt;/SPAN&gt; &lt;SPAN class="n"&gt;statement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;runs&lt;/SPAN&gt;     &lt;SPAN class="n"&gt;successfully&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;boolean&lt;/SPAN&gt; &lt;SPAN class="n"&gt;result&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;execute&lt;/SPAN&gt;&lt;SPAN class="p"&gt;();&lt;/SPAN&gt;

&lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;Check&lt;/SPAN&gt; &lt;SPAN class="k"&gt;if&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;PreparedStatement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;contains&lt;/SPAN&gt; &lt;SPAN class="n"&gt;a&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ResultSet&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
&lt;SPAN class="k"&gt;if&lt;/SPAN&gt; &lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;hasResultSet&lt;/SPAN&gt;&lt;SPAN class="p"&gt;())&lt;/SPAN&gt; &lt;SPAN class="p"&gt;{&lt;/SPAN&gt;
     &lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;Store&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ResultSet&lt;/SPAN&gt; &lt;SPAN class="n"&gt;in&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;rs&lt;/SPAN&gt; &lt;SPAN class="n"&gt;variable&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
     &lt;SPAN class="n"&gt;ResultSet&lt;/SPAN&gt; &lt;SPAN class="n"&gt;rs&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;getResultSet&lt;/SPAN&gt;&lt;SPAN class="p"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="p"&gt;}&lt;/SPAN&gt;
&lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;Close&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;PreparedStatement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;to&lt;/SPAN&gt; &lt;SPAN class="n"&gt;release&lt;/SPAN&gt; &lt;SPAN class="n"&gt;resources&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="nb"&gt;close&lt;/SPAN&gt;&lt;SPAN class="p"&gt;();&lt;/SPAN&gt;
&lt;/PRE&gt;&lt;/DIV&gt;</description>
    <pubDate>Fri, 09 Sep 2011 11:40:29 GMT</pubDate>
    <dc:creator>VolkerBarth</dc:creator>
    <dc:date>2011-09-09T11:40:29Z</dc:date>
    <item>
      <title>store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaq-p/13848034</link>
      <description>&lt;P&gt;My Android application is using ultralite DB.
I should store a primary key (pk) into a java variable.
pk datatype is uniqueidentifier; as I cannot use String neither long type
Please what is the best way to store it?&lt;/P&gt;
&lt;P&gt;Thank you very much in advance.
S&lt;/P&gt;</description>
      <pubDate>Fri, 09 Sep 2011 04:21:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaq-p/13848034</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-09T04:21:49Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848035#M4878878</link>
      <description>&lt;P&gt;Just let me hint that there are some reasons not to use UUIDs as PKs (some of them are discussed in this forum, too) and that GLOBAL AUTOINCREMENT defaults (with datatype INT/BIGINT) might be an alternative...&lt;/P&gt;
&lt;P&gt;From the &lt;A href="http://dcx.sybase.com/index.html#1201/en/dbreference/uniqueidentifier-binary-datatypes.html"&gt;docs&lt;/A&gt;:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;UNIQUEIDENTIFIER values are stored as
BINARY(16), but are described to
client applications as BINARY(36).
This description ensures that if the
client fetches the value as a string,
it has allocated enough space for the
result.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;And &lt;STRONG&gt;SQL type BINARY&lt;/STRONG&gt; is &lt;A href="http://dcx.sybase.com/index.html#1201/en/dbreference/sql-to-java-wsqltype.html"&gt;automatically mapped&lt;/A&gt; to Java type &lt;STRONG&gt;byte[]&lt;/STRONG&gt;. So that seems to be the preferred Java mapping.&lt;/P&gt;</description>
      <pubDate>Fri, 09 Sep 2011 06:48:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848035#M4878878</guid>
      <dc:creator>VolkerBarth</dc:creator>
      <dc:date>2011-09-09T06:48:47Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848036#M4878879</link>
      <description>&lt;P&gt;Thank you for your kind reply. I did not create that db but I only have to connect to its and to execute query.&lt;/P&gt;
&lt;P&gt;In this particular case, I have to get my pk &amp;lt;(uniqueidentifier datatype) and use it into another query.&lt;/P&gt;
&lt;P&gt;My error is probably because I execute a query in such a way:
SELECT * FROM mytable WHERE pk='5ad8bc00-2822-433f-88d1-2dd028e70b17';&lt;/P&gt;
&lt;P&gt;would you kindly provide us an example?&lt;/P&gt;
&lt;P&gt;Thanks in advance.
S&lt;/P&gt;</description>
      <pubDate>Fri, 09 Sep 2011 11:03:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848036#M4878879</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-09T11:03:11Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848037#M4878880</link>
      <description>&lt;P&gt;Sorry, I don't use UltraLite/UltraLiteJ so my chance to help is quite delimited...&lt;/P&gt;
&lt;P&gt;What error (SQLCODE) are you getting?&lt;/P&gt;
&lt;P&gt;Do you use an &lt;STRONG&gt;UUIDValue type&lt;/STRONG&gt; or a string or byte[] to store the UUID?&lt;/P&gt;
&lt;P&gt;You might try to use a prepared statement, here with a UUID string, such as (untested!):&lt;/P&gt;
&lt;DIV class="codehilite"&gt;&lt;PRE&gt;&lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;Create&lt;/SPAN&gt; &lt;SPAN class="n"&gt;a&lt;/SPAN&gt; &lt;SPAN class="k"&gt;new&lt;/SPAN&gt; &lt;SPAN class="n"&gt;PreparedStatement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;object&lt;/SPAN&gt; &lt;SPAN class="n"&gt;from&lt;/SPAN&gt; &lt;SPAN class="n"&gt;an&lt;/SPAN&gt; &lt;SPAN class="n"&gt;existing&lt;/SPAN&gt; &lt;SPAN class="n"&gt;connection&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;String&lt;/SPAN&gt; &lt;SPAN class="n"&gt;sql_string&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="s"&gt;"SELECT * FROM myTable WHERE pk = ?"&lt;/SPAN&gt;&lt;SPAN class="p"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;PreparedStatement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ps&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;conn&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;prepareStatement&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;sql_string&lt;/SPAN&gt;&lt;SPAN class="p"&gt;);&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;set&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="mi"&gt;1&lt;/SPAN&gt;&lt;SPAN class="p"&gt;,&lt;/SPAN&gt; &lt;SPAN class="s"&gt;'5ad8bc00-2822-433f-88d1-2dd028e70b17'&lt;/SPAN&gt;&lt;SPAN class="p"&gt;);&lt;/SPAN&gt;

&lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;result&lt;/SPAN&gt; &lt;SPAN class="n"&gt;returns&lt;/SPAN&gt; &lt;SPAN class="n"&gt;true&lt;/SPAN&gt; &lt;SPAN class="k"&gt;if&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;execute&lt;/SPAN&gt; &lt;SPAN class="n"&gt;statement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;runs&lt;/SPAN&gt;     &lt;SPAN class="n"&gt;successfully&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;boolean&lt;/SPAN&gt; &lt;SPAN class="n"&gt;result&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;execute&lt;/SPAN&gt;&lt;SPAN class="p"&gt;();&lt;/SPAN&gt;

&lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;Check&lt;/SPAN&gt; &lt;SPAN class="k"&gt;if&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;PreparedStatement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;contains&lt;/SPAN&gt; &lt;SPAN class="n"&gt;a&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ResultSet&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
&lt;SPAN class="k"&gt;if&lt;/SPAN&gt; &lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;hasResultSet&lt;/SPAN&gt;&lt;SPAN class="p"&gt;())&lt;/SPAN&gt; &lt;SPAN class="p"&gt;{&lt;/SPAN&gt;
     &lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;Store&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ResultSet&lt;/SPAN&gt; &lt;SPAN class="n"&gt;in&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;rs&lt;/SPAN&gt; &lt;SPAN class="n"&gt;variable&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
     &lt;SPAN class="n"&gt;ResultSet&lt;/SPAN&gt; &lt;SPAN class="n"&gt;rs&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;getResultSet&lt;/SPAN&gt;&lt;SPAN class="p"&gt;;&lt;/SPAN&gt;
&lt;SPAN class="p"&gt;}&lt;/SPAN&gt;
&lt;SPAN class="sr"&gt;//&lt;/SPAN&gt; &lt;SPAN class="n"&gt;Close&lt;/SPAN&gt; &lt;SPAN class="n"&gt;the&lt;/SPAN&gt; &lt;SPAN class="n"&gt;PreparedStatement&lt;/SPAN&gt; &lt;SPAN class="n"&gt;to&lt;/SPAN&gt; &lt;SPAN class="n"&gt;release&lt;/SPAN&gt; &lt;SPAN class="n"&gt;resources&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;
&lt;SPAN class="n"&gt;ps&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="nb"&gt;close&lt;/SPAN&gt;&lt;SPAN class="p"&gt;();&lt;/SPAN&gt;
&lt;/PRE&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 09 Sep 2011 11:40:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848037#M4878880</guid>
      <dc:creator>VolkerBarth</dc:creator>
      <dc:date>2011-09-09T11:40:29Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848039#M4878882</link>
      <description>&lt;P&gt;Thank you very much, it does return a resultSet and I'll investigate further ASAP.&lt;/P&gt;</description>
      <pubDate>Fri, 09 Sep 2011 12:18:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848039#M4878882</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-09T12:18:59Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848038#M4878881</link>
      <description>&lt;P&gt;try the uuid without the dashes in your example:&lt;/P&gt;
&lt;DIV class="codehilite"&gt;&lt;PRE&gt;&lt;SPAN class="n"&gt;SELECT&lt;/SPAN&gt; &lt;SPAN class="o"&gt;*&lt;/SPAN&gt; &lt;SPAN class="n"&gt;FROM&lt;/SPAN&gt; &lt;SPAN class="n"&gt;mytable&lt;/SPAN&gt; &lt;SPAN class="n"&gt;WHERE&lt;/SPAN&gt; &lt;SPAN class="n"&gt;pk&lt;/SPAN&gt;&lt;SPAN class="o"&gt;=&lt;/SPAN&gt;&lt;SPAN class="s"&gt;'5ad8bc002822433f88d12dd028e70b17'&lt;/SPAN&gt;&lt;SPAN class="p"&gt;;&lt;/SPAN&gt;
&lt;/PRE&gt;&lt;/DIV&gt;</description>
      <pubDate>Mon, 12 Sep 2011 13:27:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848038#M4878881</guid>
      <dc:creator>MCMartin</dc:creator>
      <dc:date>2011-09-12T13:27:19Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848040#M4878883</link>
      <description>&lt;P&gt;This is the error message I get:
[UltraLite Database] Cannot convert 5ad8bc002822433f88d12dd028e70b17 to
a uniqueidentifier
SQLCODE=-157, ODBC 3 State="07006"&lt;/P&gt;</description>
      <pubDate>Wed, 21 Sep 2011 05:24:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848040#M4878883</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-21T05:24:37Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848041#M4878884</link>
      <description>&lt;P&gt;What does the following return (cf. the other FAQ):&lt;/P&gt;
&lt;DIV class="codehilite"&gt;&lt;PRE&gt;&lt;SPAN class="nb"&gt;select&lt;/SPAN&gt; &lt;SPAN class="n"&gt;cast&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="s"&gt;'5ad8bc002822433f88d12dd028e70b17'&lt;/SPAN&gt; &lt;SPAN class="n"&gt;as&lt;/SPAN&gt; &lt;SPAN class="n"&gt;UNIQUEIDENTIFIER&lt;/SPAN&gt;&lt;SPAN class="p"&gt;)&lt;/SPAN&gt;
&lt;/PRE&gt;&lt;/DIV&gt;


&lt;P&gt;For SQL Anywher 12.0.1 (not Ultralite), this does return the expected value.&lt;/P&gt;</description>
      <pubDate>Wed, 21 Sep 2011 06:12:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848041#M4878884</guid>
      <dc:creator>VolkerBarth</dc:creator>
      <dc:date>2011-09-21T06:12:45Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848042#M4878885</link>
      <description>&lt;P&gt;it seems to be solved placing before "0x" and with no "-". thank you very much.
S&lt;/P&gt;</description>
      <pubDate>Wed, 21 Sep 2011 09:48:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848042#M4878885</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-09-21T09:48:21Z</dc:date>
    </item>
    <item>
      <title>Re: store uniqueidentifier - primary key</title>
      <link>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848043#M4878886</link>
      <description>&lt;P&gt;That would mean you are using the UUID as a &lt;A href="http://dcx.sybase.com/index.html#1201/en/dbreference/sqllanguage-s-7295219.html"&gt;binary literal&lt;/A&gt;, not as a string constant. And then the 0x prefix is necessary. However, it should work to use it as a string constant, too.&lt;/P&gt;
&lt;P&gt;Therefore we're glad that you have found a solution.&lt;/P&gt;
&lt;P&gt;Nevertheless it would be interesting to find out why it hasn't worked for you the way so many here have suggested...&lt;/P&gt;</description>
      <pubDate>Wed, 21 Sep 2011 10:06:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/store-uniqueidentifier-primary-key/qaa-p/13848043#M4878886</guid>
      <dc:creator>VolkerBarth</dc:creator>
      <dc:date>2011-09-21T10:06:53Z</dc:date>
    </item>
  </channel>
</rss>

