Forum > Databases

ftByte in TFieldType not exist in Lazarus. But exists in Delphi and Zeos

<< < (2/2)

marsupilami79:
Hello Fantablup,


--- Quote from: Fantablup on July 03, 2021, 07:17:28 pm ---I had a headache with this.
Some hours doing search on ftbyte in Lazarus for TFieldType.
I ise Zeos an with stByte. And i couldn't update column with TZquery because it did not have ftByte in the parameter TFieldType. And it does not have AsByte in the parameter value.

After some hours i used Value instead of AsByte(not exists) in the parameter value.

Seems to work.

--- End quote ---

You might want to check if this is supported in Zeos 8.0. We added our own fields there. So we probably support ftByte there too.

LacaK:
Can I ask if you want use/access:
- database field which is of type "byte"?
- or access parameter in SQL using TParam.AsByte ? (there exists AsByte property in Delphi)
- or access field value TField.AsByte ? (there is no AsByte property in Delphi)

Note: I added TParam.AsByte property for Delphi compatibility (however this will be only part of incomming FPC 3.4 I guess)

Fantablup:
Ohh..

AsByte is not in Lazarus either.

Yes, as byte.

I will use metadata of the DBCresultset instead for getting the field types.

Thanks for the update.

LacaK:

--- Quote from: Fantablup on July 12, 2021, 02:38:17 pm ---AsByte is not in Lazarus either.

--- End quote ---

Lazarus 2.0.12 is build with FPC 3.2.0
upcomming Lazarus 2.2.0 will be build with FPC 3.2.2

My change is in FPC TRUNK only, so if you use only stable version of Lazarus then you must wait for Lazarus which will be build with FPC 3.4.0
(it can take 1-2 years ... until new major FPC will be released)

Fantablup:
I saw that.

So i will not use the Lazarus field types. But instead the st**** field types in Zeos. Getting it with the metadata and the columns types there.

Navigation

[0] Message Index

[*] Previous page

Go to full version