Jump to content

Squamis

Members
  • Content Count

    19
  • Joined

  • Last visited

Everything posted by Squamis

  1. Squamis

    Delphi 11.3 (PPI)

    Hello! I have some interesting situation. When I open form, you can see components alignment. After editing and saving - alignment restored See at attachments. My IDE has High DPI setted to "Automatic (Screen PPI)" What you can recommend for me? Thanks bds_M0015tHvQc.mp4
  2. Helllo! Last week I decided convert my big project from Delphi+PostgresDAC (PostgresSQL) to Delphi+FireDAC (PostgresSQL). I find a lot of interesting things: 1. I can't add several "Insert" sql-queries into one TFDCommand. I've tried to use delimiter ';' - nothing. I want to use one command Execute to run several queries "Insert". 2. Some SQL-query works in different way (about speed) in SQLManager works very fast in Delphi+PostgresDAC mode works very fast in Delphi+FireDAC mode - freeze select * from vdata."systems" where ((fldidxsystem = any(:fldidxsystem::bigint[])) or (:fldidxsystem::bigint[] = '{}')) only when I rewrite SQL-query - work very fast. select * from vdata."systems" where ((fldidxsystem = any(:fldidxsystem::bigint[])) or (:fldidxsystem::varchar = '{}')) Maybe someone have any answers about it?
  3. In this sample I can't find sample with using query with parameters
  4. Next problem I very often use next type of queries select id from orders where id = any(:id) and set parameter like '{1,2}' for example but FireDAC can't recognize that paramtype I should rewrite sql-query like this select id from orders where id = any(cast(:id as bigint[])) but in this mode query freezes... What you can recommend for me?
  5. Thank for all! Thank for your time! It is really fine solution fo me: DO $$ BEGIN INSERT INTO vdata.sides(fldside_art, fldside_name) VALUES('a','b'); INSERT INTO vdata.sides(fldside_art, fldside_name) VALUES('c','d'); delete from vdata.sides where fldside_art = 'a'; END $$ Tommorow I''l try "Array DML" and "TFDScript"
  6. May be. But, I mean the next: I want in one TFDCommand component set several different queries, for example: insert into table1....; delete from table2...; and in code just run Qr1.Execute; I don't want create two TFDComponent.
  7. No. I mean fully different queries. insert into table1....; delete from table2...;
  8. Squamis

    FireDAC + TableNames with '$'

    Hello everyone! I have some problem with TDFQuery (Postgres DB). It can't recognize params in SQL-query because one table has name with double '$'. If I use macroses - it works fine, but it is a very simple query to use macroses. May be someone can help me how to fix this problem without using additional mechanisms (views, macroses, ...). May be I should add some "echo"-chars before '$' or ... P.S. It is a real project, so I can't rename tables :( with tjWLL as (select wrl.fldidxwarerule as fldidxwarerule, json_agg(wll.*) as "WARESRULESLINKS" from vdata."wares$rules" wrl inner join vdata."wares$rules$link" wll on (wrl.fldidxwarerule = wll.fldidxwarerule) where (wll.fldidxwarerule = any(:fldidxwarerule) or (case when :fldidxwarerule = '{}' then True else False end)) and :IsWLL group by wrl.fldidxwarerule ), tjWRL as (select wrl.*, wll."WARESRULESLINKS" from vdata."wares$rules" wrl left join tjWLL wll on (wrl.fldidxwarerule = wll.fldidxwarerule) where wrl.fldidxwarerule = any(:fldidxwarerule) or case when :fldidxwarerule = '{}' then True else False end ) select json_build_object('WARESRULES', to_json(tjWRL)) as "WARESRULES" from tjWRL
  9. Squamis

    FireDAC + TableNames with '$'

    Thanks
  10. Squamis

    FireDAC + TableNames with '$'

    You are completely right!
  11. Squamis

    FireDAC + TableNames with '$'

    Yes, I can use stored procedures, macroses, .... This topic just a question for understanding - it is a bug or we can do something! Just why a simple query can't be executed with standart functionality.
  12. Squamis

    FireDAC + TableNames with '$'

    Try TableName like t1$t2$t3
  13. Squamis

    FireDAC + TableNames with '$'

    Postgres?
  14. Squamis

    FireDAC + TableNames with '$'

    This is the way that I select yesturday, after this topic. P.S. If it is a bug, how Embarcadero will know about it?
  15. Squamis

    FireDAC + TableNames with '$'

    Also without results :(
  16. Squamis

    FireDAC + TableNames with '$'

    In both way TFDQuery starts recognizing params. But on try executing query: Error: can't find table vdata."wares$$rules$$link" and can't find table vdata."wares\$rules\$link"
  17. Squamis

    FireDAC + TableNames with '$'

    Thanks for your time for me! Good day!
  18. Squamis

    FireDAC + TableNames with '$'

    Good question
×