Thursday, 2010-01-28

*** withdefault has left #ingres00:17
*** grantc has joined #ingres00:26
*** withdefault has joined #ingres00:54
*** ChanServ sets mode: +o withdefault00:54
*** KermitTheFragger has joined #ingres01:31
KermitTheFraggerhi all01:33
KermitTheFraggerstupid question perhaps; but the ingres guide says a clob holds up to 2 GB01:33
grantcKermitTheFragger, that is correct01:33
KermitTheFraggerso when using UTF8, would that mean the CLOB can hold a max of 2097152 characters ?01:33
KermitTheFraggerno wait 2147483648 chars01:34
KermitTheFraggerarrgh i shouldnt do this stuff so early :)01:35
grantcit all depends on how many bytes you have per utf-8 char01:35
KermitTheFraggerone utf8 char is one byte, right ?01:35
grantci believe it can go up to 4 or 6 (for more esoteric characters/codepoints) bytes per char01:35
grantcerr no01:35
grantcif you only deal with ascii chars then yes :)01:36
KermitTheFraggerhm yeah i see your point01:38
KermitTheFraggerso the max for a character would be 4 bytes01:38
KermitTheFragger(its says in the wiki it can have a max of 4 octets)01:38
grantcor 6 but yes01:39
KermitTheFraggerare you sure about 6 grantc ?01:40
grantcwhat languages are you planning on dealing with?01:41
KermitTheFraggerthe spec says In UTF-8, characters from the U+0000..U+10FFFF range (the UTF-16 accessible range) are encoded using sequences of 1 to 4 octets.01:41
grantci think so - perhaps it was an extension01:41
KermitTheFraggerwell im implementing a Ingres Database adapter for an JDO implementation (DataNucleus)01:41
KermitTheFraggerso therefor i needed to know some bounds01:42
KermitTheFragger...dead silence.... ;-)01:43
grantcwhy not store in nclob ?01:44
grantcUTF-1601:44
grantcsince Java is UTF-16 anyway01:44
KermitTheFraggerthere is :)01:45
KermitTheFraggerim just also implementing the mapping to jdbc clob01:45
KermitTheFraggerjust being thorough :)01:46
grantcfair enough - I would imagine 4 bytes per code point would be enough01:46
KermitTheFraggeryeah that should do the trick nicely. Thanks for the insights!01:47
*** bonsaikitten has joined #ingres01:49
grantcno problem01:50
*** cthibert has joined #ingres03:16
*** Alex| has joined #ingres04:02
*** ChanServ sets mode: +o Alex|04:02
*** grantc has quit IRC04:43
*** zxiiro has quit IRC04:55
*** atrofast has quit IRC04:57
*** atrofast has joined #ingres05:00
*** zxiiro has joined #ingres05:39
*** ChanServ sets mode: +v zxiiro05:39
*** rossand has joined #ingres05:57
*** ChanServ sets mode: +o rossand05:57
*** PaulM05 has joined #ingres06:08
withdefaultHello, I'd like to pose a question to this gathering06:11
withdefaultconsider CREATE TABLE t (c1 INTEGER, c2 INTEGER, c3 VARCHAR(10), PRIMARY KEY (c1, c2));06:11
withdefaultwhat would you expect the result to be?06:11
PaulM05I could answer that but since I have an issue on it I'm probably biased ;) let's see what others think first06:13
toumi01is the issue that a nullable key is being defined?06:14
PaulM05no - it's to do with table_auto_structure06:14
withdefaulttoumi01: you're right about nullable key being defined too06:15
toumi01and what's the issue with auto structure?06:16
toumi01do folks want this to be a heap???06:16
PaulM05if auto structure is on then it creates the constraint with base table structure as the index - but that doesn't survive a copy out/copy in - you end up with a heap with 2ndry index in the new db06:17
toumi01I would have expected btree with a composite key06:17
toumi01guess I never looked at the auto strucuture details06:18
PaulM05yes that's what the create table does06:18
toumi01called away to breakfast - carry on! ;)06:19
PaulM05ok - you're right - I meant btree with 2ndry06:19
withdefaultbut does the copy work if you apply the base table structure outside of the create table?06:19
PaulM05yes06:19
withdefaultso there's a flag for the alter table06:20
withdefaultstatement that's not there when it's created under the covers06:20
PaulM05yes06:21
PaulM05I'm still trying to figure how and where it gets set06:22
withdefaultprobably written into the catalogs as part of constraint06:27
PaulM05yes that's where I'm looking at the moment06:28
withdefaultmy create table statement doesn't get as far as creating the table.  The c1 and c2 columns are nullable and the dbms server kicks out the statement because nullable columns can't be part of a pk or unique constraint06:29
PaulM05ah - that's not good06:30
PaulM05it should either give a syntax error or make it non-nullable for you06:31
withdefaultright, in the SQL standard for a table constraint like a primary or foreign key in a table definition columns of not null are implied if the clause isn't specified06:32
withdefaultwhich option makes more sense? the syntax error or the we'll make a better choice for you?06:34
PaulM05well... I've had this discussion the other day about coercion of datatypes. I think we should avoid making clever choices for people but flag it up with an error and force them to be explicit. Others take a view that that's not user-friendly, or (more relevantly) not migration-friendly06:35
PaulM05what do other DBMSs do?06:36
*** mull_ has joined #ingres06:38
PaulM05brb06:38
*** Dejan has joined #ingres06:44
Dejanhi everyone06:47
withdefaulthello06:48
PaulM05hi Dejan06:50
PaulM05I just spoke with Keith B in the migration team and he tells me that Oracle and MySQL allow primary/unique keys to have nullable columns!06:51
PaulM05he also said he thought we should be forcing the non-nullability of the column06:52
DejanPaulM05: i have Ingres databases here with tables with nullable primary keys06:53
PaulM05really?06:53
PaulM05what version?06:53
withdefaultMySQL doesn't allow nullable columns in pk, it switches the column to not null06:53
DejanPaulM05: do not know exactly, i think it is 2.606:54
PaulM05ok06:54
Dejani am working on migration of those old databases to new one06:54
PaulM05I think withdefault was saying that's not correct/current behaviour06:54
Dejanit is easy to check06:55
PaulM05well I've not actually tested it myself06:56
PaulM05I think I'm in danger of becoming an unreliable middle-man here!06:56
DejanMariaDB changes into not null06:57
Dejanjust like that06:57
Dejanlol06:57
* withdefault wanders off to a meeting06:59
Dejanhttp://codepad.org/DoXjaHio06:59
PaulM05withdefault was saying that that's what the SQL Standard specifies07:00
Dejanso SQL standard actually allows nullable PKs ?07:01
PaulM05no the SQL standard says you should make the column non-nullable (if it wasn't specified)07:26
PaulM05e.g. CREATE TABLE t (c1 INTEGER, c2 INTEGER, c3 VARCHAR(10), PRIMARY KEY (c1, c2)); - c1 and c2 should be made non-null07:27
*** PaulM05 is now known as PaulM05_mtg07:56
DejanPaulM05_mtg: yeah, that is what MariaDB does atm08:11
DejanI use latest RC08:11
Dejanno idea what Oracle's MySQL does08:12
Dejanshould be the same i think08:12
*** Mud has quit IRC08:21
*** grantc has joined #ingres08:35
*** Mud has joined #ingres08:48
*** atrofast has quit IRC08:52
*** atrofast has joined #ingres08:55
*** PaulM05_mtg has quit IRC09:33
*** Alex| has quit IRC09:53
*** Dejan has quit IRC10:01
*** cthibert has left #ingres10:08
*** cthibert has joined #ingres10:15
*** KermitTheFragger has quit IRC12:11
*** rossand has quit IRC13:04
*** cthibert has left #ingres13:13
*** Mud has quit IRC13:34
*** withdefault has left #ingres13:52
*** zxiiro has quit IRC13:58
*** rossand has joined #ingres14:17
*** ChanServ sets mode: +o rossand14:17
*** rossand has quit IRC14:28
*** zxiiro has joined #ingres15:26
*** ChanServ sets mode: +v zxiiro15:26
*** mull_ has quit IRC15:55
*** grantc has quit IRC15:57
*** grantc has joined #ingres15:58
*** grantc has quit IRC16:33
*** mull_ has joined #ingres16:41
*** mull_ has quit IRC18:02
*** zxiiro_ has joined #ingres18:15
*** zxiiro has quit IRC18:15
*** atrofast has quit IRC18:15
*** zxiiro_ has quit IRC19:20
*** cytrinox_ has joined #ingres19:20
*** zxiiro has joined #ingres19:21
*** ChanServ sets mode: +v zxiiro19:21
*** zxiiro has quit IRC19:22
*** zxiiro has joined #ingres19:23
*** ChanServ sets mode: +v zxiiro19:23
*** cytrinox has quit IRC19:36
*** cytrinox_ is now known as cytrinox19:37
*** Alex| has joined #ingres22:40
*** ChanServ sets mode: +o Alex|22:40
*** withdefault has joined #ingres22:50
*** ChanServ sets mode: +o withdefault22:50
*** Alex| has quit IRC23:07
*** Alex| has joined #ingres23:27
*** ChanServ sets mode: +o Alex|23:27

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!