insert_each_from_folder.sql 332 B

12345678910111213141516171819
  1. /* syntax version 1 */
  2. /* postgres can not */
  3. /* multirun can not */
  4. use plato;
  5. $list = (
  6. select aggregate_list(Path) from (
  7. select Path from folder("")
  8. where Type = "table" and Path like "Input%"
  9. order by Path desc
  10. limit 30
  11. )
  12. );
  13. insert into Output with truncate
  14. select
  15. count(*)
  16. from
  17. each($list)