Main   Products   Offshore Outsourcing   Customers   Partners   ContactUs  
JDBC Databases
  HXTT Access v5.2
 
  Buy Now
  Support
  Download
  Document
  FAQ
  HXTT Cobol v2.1
  HXTT DBF v5.2
  HXTT Excel v4.2
  HXTT Paradox v5.2
  HXTT Text(CSV) v5.2
  HXTT XML v1.2
Offshore Outsourcing
Oracle Data Import/Export
DB2 Data Import/Export
Sybase Data Import/Export
Free Resources
  Firewall Tunneling
  Search Indexing Robot
  Conditional Compilation
  Password Recovery for MS Access
  Password Recovery for Corel Paradox
  Checksum Tool for MD5
  Character Set Converter
  Pyramid - Poker of ZYH
   
   
   
Hongxin Technology & Trade Ltd. of Xiangtan City (abbr, HXTT)

HXTT ACCESS
GUID
Govind
2013-04-11 14:00:00.0
Hi,
There seems to be a problem while processing GUID datatype.

It's being identified as a Binary Data type( datatype = -2) instead of being identified as 1117 (Datatype OTHER + 6) as clarified by HXTT Support in another query posted by a user.

http://www.hxtt.com/support_view_issue.jsp?product=access&id=1176808563

Also please let us know the DDL to create a table with a GUID ( Replication id ) column.


GUID
Govind
2013-04-11 14:01:42.0
We are also having issues in reading and writing to an existing table with a GUID column. Hopefully if the datatype is addressed, then the reading and writing would work as designed.
Re:Re:GUID
HXTT Support
2013-04-11 18:30:58.0
>It's being identified as a Binary Data type( datatype = -2) instead of being identified as 1117 (Datatype OTHER + 6) as clarified by HXTT Support in another query posted by a user.
It has been modified to provide friend known sql type. So you will get Types.BINARY.
You can get the detailed information through
resultSetMetaData.getColumnTypeName(j) :returns GUID AUTO_INCREMENT
resultSetMetaData.getColumnType(j): return -2

typedef struct _GUID {

' unsigned long Data1;

' unsigned short Data2;

' unsigned short Data3;

' unsigned char Data4[8];

'} GUID;

For read, you can use resultSet.getBytes(j) or resultSet.getObject(j): a byte array with the length of 16
For instance, {AA5CCDD9-4BDD-4D11-920C-6E6D30FD330E} value in MS Access, the byte array will be D9 CD 5C AA (-) DD 4B (-) 11 4D (-) 92 0C (-) 6E 6D 30 FD 33 0E.

For write, you needn't to be care, because it will be automatically produced, and can't be modified in MS Access too. If you wish to update or insert it, you can use preparedStatement.setBytes(16-byte array) or SQL Escape Syntax{"varbinary" 'string'})
insert into bbb (a,b) values({"varbinary" '\x7B\x36\x43\x30\x30\x30\x30\x30\x30\x2D\x30\x30\x30\x30\x2D\x3E'}/* a hexstring for guid value */,'ccc');

If you wish to get an auto gernated key, you should use int AUTO_INCREMENT , since it's a simple int type.









Search Key   Search by Last 50 Questions




Google
 

Address: 9 Station Rd., Xiangtan City, Hunan Province, P.R. China
Postcode: 411100
Phone: (86)731-58225727
Fax: (86)731-58225727
Email: webmaster@hxtt.com
Copyright © 1999-2011 Hongxin Technology & Trade Ltd. | All Rights Reserved. | Privacy | Legal | Sitemap