Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB General » View Thread |
Messages 1 to 8 of 8 total |
Query for VarChar fields results Char fields |
Mon, Jan 21 2019 5:05 AM | Permanent Link |
Yusuf Zorlu MicrotronX - Speditionssoftware vom Profi | Hi All, in current 2.30b2 we get Char fields (filled with spaces) back if we query a table where all fields are VarChar. Is this a known bug or a normal result?
We do a "select * from mytable" and in delphi-code vtempstring:=tmyquery.fieldbyname('myvarcharfield').asstring; vtempstring is filled with spaces now! Yusuf Zorlu MicrotronX |
Tue, Jan 22 2019 4:29 AM | Permanent Link |
Yusuf Zorlu MicrotronX - Speditionssoftware vom Profi | Hi Tim, possible that this has something to do with your update to support Rio?
Yusuf Zorlu MicrotronX |
Tue, Jan 22 2019 8:52 AM | Permanent Link |
Rolf Frei eicom GmbH | I can't see this behaviour here. All fields defined as VARCHAR are trimmed as expected. Are you sure, your have VARCHAR fields and not CHAR Fields in your table?
I have just added a CHAR field to one of ,y tables and using this code... tblStudioList.Open; ShowMessage('>' + tblStudioList.FieldByName('StudioName').AsString + '<'); // VARCHAR Field tblStudioList.Edit; tblStudioList.FieldByName('StudioName2').AsString := tblStudioList.FieldByName('StudioName').AsString; tblStudioList.Post; ShowMessage('>' + tblStudioList.FieldByName('StudioName2').AsString + '<'); // CHAR Field ... Resulting in two message boxes with "mydata" and "mydata " as expected. |
Tue, Jan 22 2019 10:12 AM | Permanent Link |
Yusuf Zorlu MicrotronX - Speditionssoftware vom Profi | Fields are defined as i.e.: "NAME1" VARCHAR(36) COLLATE "UNI"
Query in DB-Manager: select '>>'+NAME1+'xx'+NAME2+'<<' from datatable; Results: >>DHL Freight GmbHxxNiederlassung Hamburg<< Query in Delphi: select * from datatable; vtext:= >>DHL Freight GmbH xxNiederlassung Hamburg << See screenshot: Yusuf Zorlu MicrotronX Attachments: edb230b2_varcharbug_001.PNG |
Tue, Jan 22 2019 10:21 AM | Permanent Link |
Yusuf Zorlu MicrotronX - Speditionssoftware vom Profi | This test was done with Delphi Tokyo 10.2.3 and ElevateDB 2.30b2
Yusuf Zorlu MicrotronX |
Tue, Jan 22 2019 10:24 AM | Permanent Link |
Yusuf Zorlu MicrotronX - Speditionssoftware vom Profi | Hmm, is it possible that there is a setting in server / engine / session to control this?
Yusuf Zorlu MicrotronX |
Tue, Jan 22 2019 10:45 AM | Permanent Link |
Yusuf Zorlu MicrotronX - Speditionssoftware vom Profi | STOP! Sorry, tests with Tokyo 10.2.3 are bad because data was corrupted from Rio install.
Close this ticket, we will test everything again with Rio installation. Again sorry to bothering with this! Yusuf Zorlu MicrotronX |
Tue, Jan 22 2019 10:53 AM | Permanent Link |
Rolf Frei eicom GmbH | Ok you have a unicode DB as I use a ANSI DB. In Ansi this seems to work as expected.
Have now done some tests on a new Unicode DB and also there I don't see this behaviour with this SQL in EDB Manager: select '>' + UniTest + '< >' + UniTestChar + '<' from test This gives me ">test< >test <" as expected. EDB and Delphi should return the exact same result, as EDB Manager is also built with Delphi. So this looks to me, as if you use a different version of the EDB components in Delphi. |
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 |