Subject | Re: [IBO] Re: Size mismatch for field... |
---|---|
Author | jwharton@ibobjects.com |
Post date | 2004-02-16T18:26:52Z |
This fix isn't released yet. I hope to clear a new release soon. It's overdue for one.
Jason
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
Sorry about my delay to answer. I spent the last 10 days in a customer,
working in a project. The few free time i have is at night, but i need
to sleep a little bit, at least... :-(
Great, it seems it's working now. I compiled my project and the queries
that wasn't openning are fine now.
Will this fix be applied to version Ab?
Can i finally upgrade to 4.3Aa or this change you sent was just a test?
Thanks!
jwharton@... escreveu:
Jason
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
Sorry about my delay to answer. I spent the last 10 days in a customer,
working in a project. The few free time i have is at night, but i need
to sleep a little bit, at least... :-(
Great, it seems it's working now. I compiled my project and the queries
that wasn't openning are fine now.
Will this fix be applied to version Ab?
Can i finally upgrade to 4.3Aa or this change you sent was just a test?
Thanks!
jwharton@... escreveu:
> I posted some code to try last night, do you see it?
>
> For some reason I am not getting emails through reliably it seems....
>
> Here it is again around line 7,000 of IBODataset.pas:
>
> procedure TIBODataSet.CheckFieldCompatibility( Field: TField;
> FieldDef: TFieldDef );
> begin
> if Field.DataType = ftFloat then Field.Size := 0;
> if ( Field.DataType = ftBCD ) {and ( Field.Size = 8 )} {Cover a past bug} then
> begin
> Field.Size := FieldDef.Size;
> if Field is TBCDField then
> with Field as TBCDField do
> Precision := FieldDef.Precision;
> end;
> if FieldDef.DataType = ftFloat then FieldDef.Size := 0;
> if (( Field.DataType = ftLargeInt ) and ( FieldDef.DataType = ftInteger )) or
> (( Field.DataType = ftInteger ) and ( FieldDef.DataType = ftLargeInt )) or
> (( Field.DataType = ftBCD ) and ( FieldDef.DataType = ftLargeInt )) or
> (( Field.DataType = ftBCD ) and ( FieldDef.DataType = ftInteger )) or
> (( Field.DataType = ftBCD ) and ( FieldDef.DataType = ftFloat )) or
> (( Field.DataType = ftFloat ) and ( FieldDef.DataType = ftLargeInt )) or
> (( Field.DataType = ftFloat ) and ( FieldDef.DataType = ftInteger )) or
> (( Field.DataType = ftFloat ) and ( FieldDef.DataType = ftBCD )) then
> //Allow this type conversion to pass.
> else
> if ( Field.DataType = ftString ) and ( FieldDef.DataType = ftMemo ) then
> //Allow this type conversion to pass.
> begin
> // Make sure it is really a string though.
> if Field.DataSize >= MaxWord then
> DatabaseErrorFmt( SFieldSizeMismatch,
> [Field.DisplayName, Field.Size, FieldDef.Size],
> Self );
> end
> else
> inherited CheckFieldCompatibility( Field, FieldDef );
> end;
>
> Replace this method, rebuild and let me know how it goes from there.
>
> Regards,
> Jason Wharton
> www.ibobjects.com