Uploaded image for project: 'CUBRID APIs'
  1. CUBRID APIs
  2. APIS-83

[Perl]Error appear when inquiring column_info information about set, multiset and sequence type

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: Perl-Aprium
    • Component/s: Perl Driver
    • Labels:
      None

      Description

      Test Build:CUBRID 2008 R4.0 (8.4.0.2019) (64bit release build for linux_gnu)
      OS: Linux 64
      Description: Error doesn't appear when foreign_key_info method like foreign_key_info('','','master','','','')

      Repro Steps
      perl column_8.pl

      Statements in column_8.pl

      $dbh->do("create table atype3(st SET, ms MULTISET, sq SEQUENCE);") or die $dbh->errstr . "  :create error\n";
      my $sth=$dbh->column_info(undef,undef,'atype3','%') or die "column_info error: $dbh->errstr";
      
      while(my $hash_ref=$sth->fetchrow_hashref()){
         print "DATA_TYPE:  $hash_ref->{DATA_TYPE}\t TYPE_NAME: $hash_ref->{TYPE_NAME}\t";
         print "TABLE_NAME: $hash_ref->{TABLE_NAME}\t";
         print "COLUMN_NAME: $hash_ref->{COLUMN_NAME}\n\n\n";
      }
      

      Actual result:

      Use of uninitialized value $type in uc at /home/perl/opt/perl5/lib/site_perl/5.14.1/x86_64-linux/DBD/cubrid.pm line 324.
      Use of uninitialized value $type in pattern match (m//) at /home/perl/opt/perl5/lib/site_perl/5.14.1/x86_64-linux/DBD/cubrid.pm line 336.
      Use of uninitialized value $type in pattern match (m//) at /home/perl/opt/perl5/lib/site_perl/5.14.1/x86_64-linux/DBD/cubrid.pm line 349.
      Use of uninitialized value $type in pattern match (m//) at /home/perl/opt/perl5/lib/site_perl/5.14.1/x86_64-linux/DBD/cubrid.pm line 361.
      Use of uninitialized value $type in pattern match (m//) at /home/perl/opt/perl5/lib/site_perl/5.14.1/x86_64-linux/DBD/cubrid.pm line 366.
      .........
      ........
      
      DATA_TYPE:  12   TYPE_NAME:     TABLE_NAME: atype3      COLUMN_NAME: ms
      
      
      DATA_TYPE:  12   TYPE_NAME:     TABLE_NAME: atype3      COLUMN_NAME: sq
      
      
      DATA_TYPE:  12   TYPE_NAME:     TABLE_NAME: atype3      COLUMN_NAME: st
      
      
      
      1. APIS-83_FIX01.creview
        25 kB
        李金虎
      2. column_8.pl
        0.9 kB
        ZouJing

        Activity

        Hide
        jinhu 李金虎 added a comment -

        Fix in trunk, revision: 1447
        Merge into RB-8.4.1, revision: 1448
        Merge into RB-8.4.3, revision: 1449
        Merge into RB-8.4.4, revision: 1450

        Now, the result is as below:

        [jinhu@NC-VM-PL-DEV-33 t]$ perl apis-83-colomn_info.t 
        DATA_TYPE:  0    TYPE_NAME: NULL        TABLE_NAME: atype3      COLUMN_NAME: st
        
        
        DATA_TYPE:  0    TYPE_NAME: NULL        TABLE_NAME: atype3      COLUMN_NAME: ms
        
        
        DATA_TYPE:  0    TYPE_NAME: NULL        TABLE_NAME: atype3      COLUMN_NAME: sq
        
        
        [jinhu@NC-VM-PL-DEV-33 t]$
        
        Show
        jinhu 李金虎 added a comment - Fix in trunk, revision: 1447 Merge into RB-8.4.1, revision: 1448 Merge into RB-8.4.3, revision: 1449 Merge into RB-8.4.4, revision: 1450 Now, the result is as below: [jinhu@NC-VM-PL-DEV-33 t]$ perl apis-83-colomn_info.t DATA_TYPE: 0 TYPE_NAME: NULL TABLE_NAME: atype3 COLUMN_NAME: st DATA_TYPE: 0 TYPE_NAME: NULL TABLE_NAME: atype3 COLUMN_NAME: ms DATA_TYPE: 0 TYPE_NAME: NULL TABLE_NAME: atype3 COLUMN_NAME: sq [jinhu@NC-VM-PL-DEV-33 t]$
        Hide
        jinhu 李金虎 added a comment -

        The type infomation in the result is not right. It's the issue about CUBRID.
        It can be reproduced by the below cmd in CSQL:

        csql> create table atype3(st SET, ms MULTISET, sq SEQUENCE);
        csql> show create table atype3;
        
        === <Result of SELECT Command in Line 1> ===
        
          TABLE                 CREATE TABLE        
        ============================================
          'atype3'              'CREATE TABLE [atype3] ([st] SET OF , [ms] MULTISET OF , [sq] SEQUENCE OF ) COLLATE iso88591_bin'
         
        csql> show columns from atype3 like '%';
        
        === <Result of SELECT Command in Line 1> ===
        
          Field                 Type                  Null                  Key                   Default               Extra               
        ====================================================================================================================================
          'st'                  NULL                  'YES'                 ''                    NULL                  ''                  
          'ms'                  NULL                  'YES'                 ''                    NULL                  ''                  
          'sq'                  NULL                  'YES'                 ''                    NULL                  ''                  
        
        
        Show
        jinhu 李金虎 added a comment - The type infomation in the result is not right. It's the issue about CUBRID. It can be reproduced by the below cmd in CSQL: csql> create table atype3(st SET, ms MULTISET, sq SEQUENCE); csql> show create table atype3; === <Result of SELECT Command in Line 1> === TABLE CREATE TABLE ============================================ 'atype3' 'CREATE TABLE [atype3] ([st] SET OF , [ms] MULTISET OF , [sq] SEQUENCE OF ) COLLATE iso88591_bin' csql> show columns from atype3 like '%'; === <Result of SELECT Command in Line 1> === Field Type Null Key Default Extra ==================================================================================================================================== 'st' NULL 'YES' '' NULL '' 'ms' NULL 'YES' '' NULL '' 'sq' NULL 'YES' '' NULL ''
        Hide
        cn14130 欧明宝[Bom Owen] added a comment -

        Test Build: 9.1.0.0204
        Test OS: Linux 64
        perl driver: 9.1.0.001
        Test Result: pass
        RB-8.4.1, RB-8.4.3, RB-9.0.0 will be validated by daily qa test

        Show
        cn14130 欧明宝[Bom Owen] added a comment - Test Build: 9.1.0.0204 Test OS: Linux 64 perl driver: 9.1.0.001 Test Result: pass RB-8.4.1, RB-8.4.3, RB-9.0.0 will be validated by daily qa test

          People

          • Assignee:
            jinhu 李金虎
            Reporter:
            zoujing ZouJing
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: