# Delphi 10.3 + FireDAC + PostgreSQL UID parameter + DA 9.6.113

**URL:** https://talk.remobjects.com/t/delphi-10-3-firedac-postgresql-uid-parameter-da-9-6-113/19236
**Category:** Data Abstract
**Created:** [April 21, 2019, 6:01am UTC](https://talk.remobjects.com/t/delphi-10-3-firedac-postgresql-uid-parameter-da-9-6-113/19236 "2019-04-21T06:01:28Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![\_Koncz\_Timea](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/_/ecc23a/32.png) [@\_Koncz\_Timea](https://talk.remobjects.com/u/_Koncz_Timea)
#### Post date: [April 21, 2019, 6:01am UTC](https://talk.remobjects.com/t/delphi-10-3-firedac-postgresql-uid-parameter-da-9-6-113/19236/1 "2019-04-21T06:01:29Z")

</div>

Hi,

We try to open a query with UID parameter and the database system gives operator does not exist: uuid = character varying.  
Probably is caused by the parameter type settings in uDAFireDACDriver.

Best regards.

---

<div class="post-metadata">

### Author: ![EvgenyK](https://talk.remobjects.com/user_avatar/talk.remobjects.com/evgenyk/32/16_2.png) [@EvgenyK](https://talk.remobjects.com/u/EvgenyK)
#### Post date: [April 22, 2019, 8:02am UTC](https://talk.remobjects.com/t/delphi-10-3-firedac-postgresql-uid-parameter-da-9-6-113/19236/2 "2019-04-22T08:02:10Z")

</div>

Hi,

what datatype is used for this field in Schema Modeler, `String`/`WideString`?  
if you specify valid datatype, will it work?

can you provide your DDL script for this table?  
you can drop email to support@ if this info is private.

---

<div class="post-metadata">

### Author: ![\_Koncz\_Timea](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/_/ecc23a/32.png) [@\_Koncz\_Timea](https://talk.remobjects.com/u/_Koncz_Timea)
#### Post date: [April 22, 2019, 5:43pm UTC](https://talk.remobjects.com/t/delphi-10-3-firedac-postgresql-uid-parameter-da-9-6-113/19236/3 "2019-04-22T17:43:42Z")

</div>

> [@EvgenyK](#):
>
> `WideString` ?

We 've got this issue when we have a table with primary key with UUID type. If we set a dynamic where for this field to some UID value (if I set the constant type as datGUID, the server will receive this parameter type as datGUID else if I don’t set this parameter then it’s seen as datWideString), that value are appearing correct on server side, but it doesn’t override the parameter $1 of SQL with this value. For any other types it work fine. In data modeler the field type is datGUID.

---

<div class="post-metadata">

### Author: ![\_Koncz\_Timea](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/_/ecc23a/32.png) [@\_Koncz\_Timea](https://talk.remobjects.com/u/_Koncz_Timea)
#### Post date: [April 25, 2019, 6:12am UTC](https://talk.remobjects.com/t/delphi-10-3-firedac-postgresql-uid-parameter-da-9-6-113/19236/4 "2019-04-25T06:12:10Z")

</div>

Hi,

We managed to solve the problem:  
-on client side DynamicWhere needs data type for constant expression (if server is with zeos driver you don’t need it)  
-on server side in the connection string you must include GUIDEndian=Big parameter if you are using PostgreSQL and FIreDAC driver

Best regards.

---

<div class="post-metadata">

### Author: ![jeffw](https://talk.remobjects.com/letter_avatar_proxy/v4/letter/j/bbce88/32.png) [@jeffw](https://talk.remobjects.com/u/jeffw)
#### Post date: [January 7, 2021, 2:17am UTC](https://talk.remobjects.com/t/delphi-10-3-firedac-postgresql-uid-parameter-da-9-6-113/19236/5 "2021-01-07T02:17:56Z")

</div>

Thanks for this. As an example, with FireDAC, your query should use look like this:

SELECT serial\_number FROM “&table\_name” WHERE ml\_uuid = { fn CONVERT(:ml\_uuid, uuid) }
