Re: Ignite with POJO persistency in SQLServer

2018-10-01 Thread slava.koptilin
Hello, I am sorry for the late response. Yes, I would try to use BINARY. Thanks, S. -- Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Ignite with POJO persistency in SQLServer

2018-08-10 Thread michal23849
Thanks for this, this clarifies a lot. Could you only advise which data type should be used and how to map the field of type which is my class? Should I use BINARY or this cannot be handled at all? My intuition is that I should map the my.package.ListingCode to the java.sql.Types.JAVA_OBJECT.

Re: Ignite with POJO persistency in SQLServer

2018-08-10 Thread Вячеслав Коптилин
Hello, Perhaps, I'm missing something but it seems that LONGVARBINARY is not supported by Apache Ignite. The full list of available types can be found here: https://apacheignite-sql.readme.io/docs/data-types Thanks, S. ср, 8 авг. 2018 г. в 18:52, michal23849 : > Hi All, > > I tried mapping the

Re: Ignite with POJO persistency in SQLServer

2018-08-08 Thread michal23849
Hi All, I tried mapping the fields in number of different combinations based on the above, but all the time I am failing with the SQLServerException: The conversion from UNKNOWN to UNKNOWN is unsupported. The mappings I used in the following structure included:

Re: Ignite with POJO persistency in SQLServer

2018-08-08 Thread michal23849
Thank you for the help! -- Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Ignite with POJO persistency in SQLServer

2018-08-08 Thread aealexsandrov
Yes. In case if you don't want to store it as objects then you can move this fields to original object: class a{ Int a; class b; } class b{ int b; int c; } You can change it as next: class a{ int a, int b; int c; } -- Sent from: http://apache-ignite-users.70518.x6.nabble.com/

Re: Ignite with POJO persistency in SQLServer

2018-08-08 Thread michal23849
Andrei, As I understand you - the only way to map embedded classes is by using mapping them as objects and store as BLOBs or other VARBINARY fields in SQL database? No way to decompose them into separate fields in the tables? Eg. ListingCode has: private String code; private String

Re: Ignite with POJO persistency in SQLServer

2018-08-07 Thread aealexsandrov
>From web console sources I see next mapping: {"dbName": "BIT", "dbType": -7, "signed": {"javaType": "Boolean", "primitiveType": "boolean"}}, {"dbName": "TINYINT", "dbType": -6, "signed": {"javaType": "Byte", "primitiveType": "byte"}, "unsigned": {"javaType": "Short",

Re: Ignite with POJO persistency in SQLServer

2018-08-07 Thread aealexsandrov
I am not fully sure but according to the specification of java.sql.Types you can try to use next for Java objects: https://docs.oracle.com/javase/7/docs/api/java/sql/Types.html#JAVA_OBJECT https://docs.oracle.com/javase/7/docs/api/java/sql/Types.html#OTHER

Re: Ignite with POJO persistency in SQLServer

2018-08-07 Thread michal23849
Hi Anrei, My goal is to map the data using CacheJdbcPojoStore and save the data that I already have in Ignite to SQLServer. The data model has embedded classes and I don't know how to map them. Currently I got the following setup, which works fine, but that is only the subset of data.

Re: Ignite with POJO persistency in SQLServer

2018-08-07 Thread aealexsandrov
Hi, You have pogo class - your.package.EquityClass wuth next fields: Long equityID; private ListingCode firstCode; private String equityName; private String equityType; private String equityClass; private Set listings; and you are going to store in into ignite. In

Ignite with POJO persistency in SQLServer

2018-08-07 Thread michal23849
Hi, I have my Ignite that has complex objects classes with not only generic Java data types, but also other classes and arrays of classes. I managed to setup my PojoStore that successfully writes (write-behind) data to SQL Server table for all generic data types. I see no examples or