Menu

getColumns in DatabaseMetaData not working

Help
2001-11-20
2002-08-08
  • Pritpal Dhaliwal

    I have the table above,

    CREATE TABLE "musicType" (
      "musicTypeID" int4 DEFAULT nextval('"musicType_musicTypeID_seq"'::text) NOT NULL,
      "musicTypeName" varchar(30) NOT NULL,
      CONSTRAINT "musictype_pkey" UNIQUE ("musicTypeID"),
      CONSTRAINT "musicType_pkey" PRIMARY KEY ("musicTypeID")
    );

    i am calling the following function on datababseMetaData
    getColumns(this.database,null,tableName,null);

    I don't get any columns back, does anyone know why?

    I get columns back on all the other tables.

    Thanks in Advance,

    Pritpal Dhaliwal

     
    • Keve Müller

      Keve Müller - 2002-08-07

      Forget the quotes around the table and column names
      You should not quote the identifiers - then everything works fine.

      The meta data code needs to be cleaned up with respect to quoted mixed case identifiers.

      Keve

       
      • Nobody/Anonymous

        Isn't it so that if you don't use quotes around identifiers, you will not get mixed case, just lower case? It is like that in the postgresql-jdbc, and changing this would require a lot of changes in the sourcecode for developers who wants to change jdbc-drivers.

         

Log in to post a comment.