Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB General » View Thread |
Messages 1 to 5 of 5 total |
Silent data loss in assignments |
Wed, Mar 28 2007 10:59 AM | Permanent Link |
"Ole Willy Tuv" | create table test
( col1 char(1), col2 varchar(1), col3 smallint, col4 integer ); insert into test values ('abc','abc',32768,2147483648); select * from test The character string values have silently been truncated to 'a' and the numeric values to 0. I'd expect that string data truncation and numeric overflows in assignments would raise proper exceptions. Ole Willy Tuv |
Thu, Mar 29 2007 6:43 AM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Ole,
<< I'd expect that string data truncation and numeric overflows in assignments would raise proper exceptions.>> Only in CLI-level access (ODBC) do we give warnings regarding string truncation, etc. -- Tim Young Elevate Software www.elevatesoft.com |
Thu, Mar 29 2007 6:52 AM | Permanent Link |
"Ole Willy Tuv" | Tim,
<< Only in CLI-level access (ODBC) do we give warnings regarding string truncation, etc. >> Yes, but would you consider to raise it at the SQL engine level ? Silent data loss ain't pretty Ole Willy Tuv |
Fri, Mar 30 2007 10:58 AM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Ole,
<< Yes, but would you consider to raise it at the SQL engine level ? >> I'll have to think about this a bit more. There is no "SQL Level" in EDB, so that means that it would get raised during simple assignments from a TEDBTable, TEDBQuery, also. I don't want to introduce another 8708 type of situation that is just a giant pain in the ass for everyone. << Silent data loss ain't pretty >> Yes, but it's not like EDB is doing so on its own - someone is trying to assign a value that is incompatible with the defined column as it exists. -- Tim Young Elevate Software www.elevatesoft.com |
Fri, Mar 30 2007 11:16 AM | Permanent Link |
"Jose Eduardo Helminsky" | Tim
IMO, data loss *always* can be reported to the user but you can introduce a new event to developer deal with. I think this is a very good way to deal with different point of view from developers. The behavior of some operations can be customized by developer. You just point the standard behavior. For example: procedure TEDBDataset.OnSpecialSituation(Sender: TObject: KindOfError: String; RaiseException: Boolean); begin if KindOfError = 'bla bla bla' then begin RaiseException := False; end; end; Eduardo |
This web page was last updated on Tuesday, September 17, 2024 at 04:19 AM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |