Ticket #98 (closed defect: duplicate)

Opened 20 years ago

Last modified 16 years ago

Object.edit Scaffolding Errors With Dates and Integers

Reported by: dhughes Owned by: joe.rinehart
Priority: normal Milestone:
Version: 2.0.304 Severity: major
Keywords: Cc:

Description

I have a table which has a datetime and integer columns. When I scaffold an edit form for this table the resulting CFML has this code (as an example):

<cfinput type="text" class="input" maxLength="0" id="postedByUserId" name="postedByUserId" value="#Entry.getpostedByUserId()#" />

As you can see this has a maxLength of 0. This causes CF to throw an error:

Oops! Message Attribute validation error for tag CFINPUT. Detail The value of the attribute MAXLENGTH is invalid. The value specified, "0.0", must be greater than "0.0".

Change History

Changed 20 years ago by joe.rinehart

  • owner changed from somebody to joe.rinehart

Doug,

What DB server is this on? Could you maybe post a DDL script for the table?

Thanks,

Joe

Changed 20 years ago by joe.rinehart

  • milestone changed from User Reported Issues (with full information) to Defects Awaiting More Information

Changed 20 years ago by dhughes

Db type = mssql (2005)

The bug occured with a BER version of Unity.

The DB is the ReactorBlog? database, if you want the whole schema. I established no relationships in the reactor.xml, I was just playing arround with Unity.

DDL (generated by SQL server):

/****** Object: Table [dbo].[Entry] Script Date: 07/17/2006 20:45:15 ******/ SET ANSI_NULLS ON ; SET QUOTED_IDENTIFIER ON ; SET ANSI_PADDING ON ; CREATE TABLE [dbo].[Entry](

[entryId] [int] IDENTITY(1,1) NOT NULL, [title] [varchar](200) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL, [preview] [varchar](4000) COLLATE SQL_Latin1_General_CP1_CI_AS NULL, [article] [text] COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL, [publicationDate] [datetime] NOT NULL CONSTRAINT [DF_Entry_publicationDate] DEFAULT (getdate()), [postedByUserId] [int] NOT NULL, [disableComments] [bit] NOT NULL CONSTRAINT [DF_Entry_disableComments] DEFAULT (0), [views] [int] NOT NULL CONSTRAINT [DF_Entry_views] DEFAULT (0), [totalRating] [int] NOT NULL, [timesRated] [int] NOT NULL,

CONSTRAINT [PK_Entry] PRIMARY KEY CLUSTERED

(

[entryId] ASC

)WITH (PAD_INDEX = OFF, IGNORE_DUP_KEY = OFF, FILLFACTOR = 90) ON [PRIMARY] ) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]

; SET ANSI_PADDING OFF ; ALTER TABLE [dbo].[Entry] WITH NOCHECK ADD CONSTRAINT [FK_Entry_User] FOREIGN KEY([postedByUserId]) REFERENCES [dbo].[User] ([userId]) ; ALTER TABLE [dbo].[Entry] CHECK CONSTRAINT [FK_Entry_User]

Changed 20 years ago by joe.rinehart

  • status changed from new to closed
  • resolution set to duplicate

This got fixed a week or so ago.

Changed 16 years ago by cfgrok

  • milestone Defects Awaiting More Information deleted

Milestone Defects Awaiting More Information deleted

Note: See TracTickets for help on using tickets.