Uploaded image for project: 'Archiva (Retired)'
  1. Archiva (Retired)
  2. MRM-735

Database on MS SQL 2000/2005 fail to be created due to too column length

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • 1.0, 1.0.1
    • None
    • system
    • None
    • Win XP
      Tomcat 5.5
      MS SQL 2000 / 2005
      MS SQL 2005 JDBC Driver, v1.2

    Description

      Some column lengths in the datamodel exceed the restrictions of MS SQL Server using the default String jdbc-mapping of jpox (varchar)

      These are according to package.jdo:

      • Table: ARCHIVA_PROJECT
        -> Columns: description
      • Table: ARCHIVA_LICENSES
        -> Columns: comments
      • Table: ARCHIVA_REPOSITORY_PROBLEMS
        -> Columns: message

      The 2005 Jdbc driver uses the nvarchar datatype in case of varchar jdbc types. The maximum length here would be 4000 bytes.

      Some other db systems should have the same problem, as I could see from their specs, but I'm not an expert (Oracle: 4000 bytes, DB2: 4-32k depending on page size).

      A possible fix for MS SQL is, not to provide any length. Instead we could use the jdo jdbc-type. I tested it with using the jdbc-type="LONGVARCHAR". Then jpox uses ntext column types for those fields.

      Unfortunatly, there is no way to define this parameter within modello.

      Attachments

        Issue Links

          Activity

            People

              brett Brett Porter
              twdev Thomas Winkler
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: