我有4个工作台FMW文件,每次从外部源提取数据,通过各种变压器运行,that then insert and update data into 6 related tables.
The First FMW is updating traffic accidents.
httpcaller transformer上的上体代码包含每周必须手动更新的开始和结束日期。
这是upload body参数中的代码:
I want to replace the manual process by adding a scheduled task to run every Monday AM morning,计算并传递计算的开始和结束日期。
我有一个创造者变压器要启动,后面是2个日期时间计算器。
第一个使用@datetimenow()计算开始日期,减去8天,而第二个日期时间计算器确定enddate@datetimenow()减去2天。
However not sure how to code this to pass in the value from StartDate and EndDate.
Any ideas?
我试过了,but doesn't work.
谢谢
我正在处理一个XML文件目录。I have set the source dataset to just .../*.xml
然而,我想根据源文件名保存结果。How do I set the output filename to be the same as the input filename?
你好,
I am new-ish to FME and primarily used model builder for previous needs which may show in how this model was created.
所以我在读SDE,更改一些字段名以及将数据同时输出到kmz和单个形状文件到压缩文件夹。并不是所有的特性类都在其表中有nfid,所以我不仅对输出文件名使用这个参数,but also to select the line with the specified NFID and then buffer to select surrounding features.
I created this to run for one project at a time using a parameter NFID which is basically a project name/number to select the correct data and to name the output folder and kmz file.
我想进一步扩展它,让它在理想情况下运行在一个NFID列表中,最终从一个良好的工作表中读取,并在表中更新项目状态时基于这些值运行,但一旦我可以让它重置并为输入的每个NFID运行,这将是下一步。
Current Process: input project specific identifier NFID as a user parameter then run the model
一旦模型成功运行,我将撤消上次重置输出名称的操作:
Any ideas on how this can be run for multiple NFID input without recreating this entire model or having to undo last action after running the model?
我也很想知道如何根据谷歌工作表中的项目状态来运行每个NFID。
Thanks!
我要做的是从一个python启动脚本中获取一个字符串数组,然后从工作台的其余部分(特别是一个SQL执行器和emailer)访问它。what i have so far is made a global variable like so:
global users_to_fixusers_to_fix = []
然后将字符串附加到该数组中。
and here are my tranformers:
这是蟒蛇:
i have gotten this solution fromhttps://knowledge.亚搏在线safe.com/questions/58082/passing-parameters-from-a-python-script-tool-to-a.html
i am getting the following error:
Python Exception: Failure to convert list unicode values to native UTF-8 values.Error encountered while calling function `getUsersToFix'f_8(PythonFactory): PythonFactory failed to process feature
i'm thinking there must be a better way to do this.because i'm not actually dealing with features,我正在处理我们的agol数据库的用户名列表。
My 亚搏在线workflow requires reading .zip files,containing multipleXML's containing the data I require.
The .zip file name is aconcatenation of the following information:
VariableProcessname1_VariableProcessname2_TransactionID_Date_Variable.zip
At this stage I have only been successful reading in multiplefiles using the direct file path followed by *.zip to reference all files.
但是存储.zip文件的文件夹中有数千个项目,and for this particular process I need toonlyuse the .zip files which are of aset date range – ie.the last two days.
我已尝试(未成功)以下方法读取所需的文件:
我认为一些Python代码(可能与文件路径阅读器结合使用)可能是最好的解决方案?如果有人能够提供代码的示例,我会非常感谢。
Hi,
Is there a way to add transformers based on a list of variables.如:为每个变量列表中,run all the data through a defined set of transformers,and with each iteration change what those transformers do based on the variable?
Thanks!
Hi
I am still new to FME and would like to find out the best/easiest/quickest way to calculate lengths of pipe sections.在这种情况下,S01和F01之间的距离(3.8-0.6=3.2)。棘手的一点是,有时每个检查ID有超过1个管段需要计算,ie S02/F02,S03/F03 etc.
Thanks in advance
J
你好,would be glad to find the solution: to use comma in variable by WorkspaceRunner.For example,i have Mainprozess and subprozess.In mainprozess will be define: what IDs will be needed.在进入子程序之后,我需要通过data import只导入具有这些ID的数据(导入所有数据需要花费太多时间)。So i need to write Comma in the WorkspaceRunner,like this:
obj_id in {'1000000000000106996011','1000000000000118176003'}
But this statement does not work as i needed.Do u have some ideas?Greetings,安娜
Hi there,
我正在尝试从某个目录中消化多个csv文件。要做到这一点,我创建了一个csv阅读器,它有一个带有参数“uuu”的源csv文件夹。
I need to remove the processed file from this directory after processing which I would do via python shutdown script by getting the filename that has to be removed (actually - it would be moved into a directory).
In the past when I only processed one file,我可以直接从读卡器中获取文件位置,which is of course now the
I have used an Attribute-Exposer to get the filename- but I haven't figured out how to use it in my shutdown script?Am I missing something obvious here?Is there a way to either:
- set a Python variable with the filename (I would be surprised)
or
-在运行时设置发布参数?
Thanks in advance!