Hi, Sachin! On Mar 16, Sachin Setia wrote: > Thanks sir for your reply > I have done two thing > 1. First commenting some code to remove the error we get when we try to > create unique blob > file=sql/sql_table.cc > line no=3877
It'd be easier to read, if you'd sent a patch instead. > /* > * Gsoc 2016 > * I am implementing this so comment this stuff out > */ > // if (!column->length) > // { > // my_error(ER_BLOB_KEY_WITHOUT_LENGTH, MYF(0), column->field_name.str); > // DBUG_RETURN(TRUE); > // } > > 2. here I am assuming this thing for for just prototyping > Assumption My table will just contain two column first will be primary key > second will be unique blob > So basically what i am doing is create a custom unique key and passing it > to mi_create > Of course in real patching i will replace this code with logic like if i > have m unique blobs (i will find this using key_length ==0) > create m unique key array and pass it > > file=storage/myisam/ha_myisam.cc > line no=2067 > //some tweak in share for prototype > share->keys--; > share->uniques=1; > MI_UNIQUEDEF uniquedef; > MI_KEYDEF keydef_blob=*(keydef+1); > bzero((char*) &uniquedef,sizeof(uniquedef)); > uniquedef.keysegs=1; > uniquedef.seg=keydef_blob.seg; > uniquedef.null_are_equal=1; > > /* TODO: Check that the following fn_format is really needed */ > error= mi_create(fn_format(buff, name, "", "", > MY_UNPACK_FILENAME|MY_APPEND_EXT), > share->keys, keydef, > record_count, recinfo, > 1, &uniquedef, > &create_info, create_flags); > > If i am doing it wrongly please let me know Looks fine for a prototype. Very good! Regards, Sergei Chief Architect MariaDB and secur...@mariadb.org _______________________________________________ Mailing list: https://launchpad.net/~maria-developers Post to : maria-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~maria-developers More help : https://help.launchpad.net/ListHelp