Using transformers to modify data.
Recently active
Hello ,Could I create tables (Feature classes ) in Arcmap by using Arcsde writer even if there is no content ( empty content )my problem : I have to export the data required monthly from Fme .sometimes ,no data output .sometimes there are new data .in case no data ,i would like to have always feature class , when I show the table of content in arcmap ,I see it is empty .even if there is output or not ,i would like to have monthly feature class has the same name . How could I achieve it ?fme 2021
Looking for ideas on geocoding from text blocks. Each feature has a block of text (~50 to 100 words) describing an incident. More than one place could be mentioned so results would likely include more than one place. But in any case the goal is to geocode based on places mentioned in the text. An example might look like this: "...Something happed in Streetsville and people were walking toward Placeville." And we would want geocoding results from Streetsville and Placeville.
I've 6 SQL statements in SQL executor. I'm trying to execute these 6 statements only when name_<1-6> value exists. If any of this value is NULL or missing, then that corresponding SQL statement needs to be skipped to avoid error. insert into demo.lu_test values (@Value(id), '@Value(name_1)', 1);insert into demo.lu_test values (@Value(id), '@Value(name_2)', 2);insert into demo.lu_test values (@Value(id), '@Value(name_3)', 3);insert into demo.lu_test values (@Value(id), '@Value(name_4)', 4);insert into demo.lu_test values (@Value(id), '@Value(name_5)', 5);insert into demo.lu_test values (@Value(id), '@Value(name_6)', 6); @david_r Please suggest. Thanks!
I'm using the feature caching Run option.I'm reading a postgresql table (no geometry) not a postGIS table. Unfortunately it is rather lengthy. For each record, I'm getting Adding to Spatial Index (paraphrasing) and after the last record a rather long pause before the processing progresses.This might be fine for small record sizes but it is crippling for larger ones.The bottom line is shouldn't there be no spatial index created as long as the reader has no geometry in any case - feature caching or not?Here are my details:Edition: FME Database Edition (node locked-crc) Version: FME(R) 2019.1.0.0 (20190704 - Build 19604 - WIN64) Locale: en_US Codepage: 1252 (ANSI - Latin I) Registration Key: 1-542-353-546 Customer Number: Home Folder: C:\\Program Files\\FME\\Beta\\ Operating System: Microsoft Windows 10 64-bit (Build 17763) Thanks for any assistance or bug fixing.
I wanna be able to define a global python function (perhaps in the startup scirpt?) like this:def dosomething(number)new_number = number + ... doing something with itreturn new_number then, en would like to reuse this global function many times at different moment in my workspace on many different attributes that has to go through the same treatment. During the workflow of data_a, I'd call a pythoncaller this way:newNumber = dosomething(feature.getAttribute('num_1'))feature.setAttribute('num_1',newNumber)newNumber = dosomething(feature.getAttribute('num_2'))feature.setAttribute('num_2',newNumber) During the workflow of data_b, I'd call a pythoncaller this way too:newNumber = dosomething(feature.getAttribute('num_a'))feature.setAttrivute('num_a',newNumber)newNumber = dosomething(feature.getAttribute('num_b'))feature.setAttrivute('num_b',newNumber) I tried the same using a pythonCaller inside a customTransformer, but
HI all, does someone have (or has someone had experience with this):JPEG reader: `C:\\Users\\USER1\\AppData\\Local\\Temp\\wbrun_1699971545629_16788\\fmetmp_4\\ImageFetcher1699971789428_20972' exists but could not be opened. File contents may be invalid, or the file format may not be supportedJPEG reader: Failed to open the dataset 'C:\\Users\\USER1\\AppData\\Local\\Temp\\wbrun_1699971545629_16788\\fmetmp_4\\ImageFetcher1699971789428_20972'. Please ensure source data is valid and correct reader is selected.The funny thing is I never had an issue with that and it was working perfectly.Any ideas?
Hi, I have a CAD file with 1000 polygon, 500 out 1000 are shifted 0.2m. I want to keep only 500 regardless of the shifting. please advice. thanks
The workbench I am putting together contains a feature reader to a dynamic write in several locations. The workbench itself detects shape files in a folder location, validates projection, geometry and AssetID attributes. Then writes out any identified errors to a shape file for upload in another step.The dynamic write of the "errors" shape file works however the dynamic write of the upload file encounters a warning where the below appears in the log: Cannot define schema for '@Value(ENCODED,fme_feature_type)' as the feature does not contain schema information. While we have the schema mismatch the remainder arrive correctly.The features arrive with the new layer name that I want to use. Testing my workbench I have found that the dynamic writer performs as expected (and outputs the shape file) for every stage up to exposing the fme_feature_type, mapping the new layer name and setting the dynamic reader to the new layer name.I have tested this in the latest version (20
Hello, I am trying to create a folder with a prefix of Run_ and have the current datetime as the folder name. I am very new to FME and I am not sure what I am doing wrong with the setup that nothings gets created in the path I have as destination (screenshot below). I appreciate any help.
I have a work bench that transforms data from multiple sources and then inserts only the new records from the combined data into a table using a merge transformer and Feature Writer. For auditing purposes I need to log how many records were written to a table in the same Database as well as pass that info back to FME Server to include in a email via automations. I am able to do this currently with the summary output of the Feature writer, however I would also like to pass the count of the existing records and also set the total written to 0 rather than the undefined that gets returned when there is no new records to add. I've tried using counters but either I'm using them incorrectly or I'm missing some steps as the flow doesn't continue down the path when there are no new records.
HelloI want to create a point in the middle of each line in my file. Each of these lines is made up of only 2 vertices. Can you guide me to achieve this. Thanks in advance
Here i have some Lines extracted from DWG and thought i set them to the correct projection. all seem right except for one file that is way off "Asbuilt - Sewer Existing" I noticed that the autocad_origion x,y are the correct extents but the geometry have different xy coordinates. any ideas on how to set this correctly would be appreciated. Many Thanks!
I'm looking for some advice to get me started on creating a workflow. I'm an intermediate FME user but this problem has got me stumped! I'm dealing with roughly 100 areas that require tree planting. Each planting area will be a different size depending on the environment. Once each area is planted, we need to monitor 20% of the area to determine the success rate. The monitoring plots are 10 x 10 metres, so area of 100 sqm. The plots need to be placed at random and I need to find out how many monitoring plots can be fit wholly within a planting area where the total area of the plots is at least 20% of the total planting area. For example, if the planting area is 3000sqm, I would need to assign 6 x plots.20% of 3000 is 600. 600sqm would be 6 x plots. Any help or advice would be appreciated.
Hi, When i try to connect open service: https://gis4.waimatedc.govt.nz/arcgis/rest/services/Public/RoadClosure_Waimate_Active_Planned/MapServer using "Esri ArcGIS Feature Service" reader, I get Python exception error. There is no authentication required as its open service. The fact that I can use HTTPCaller and get the data with query service tells me, this service doesnt require authentication. Am I missing something? I tried few other rest service from this council with no luck. Python Exception <HTTPError>: 403 Client Error: Forbidden for url: does this error means anything to do their IT system infrastructure? Any help would be appreciated? Cheers,
I want to read a Geopackage file, but when I run the FeatureReader transformer, it creates a new geopackage file with the name of "file name"_0.gpkg so as cannot be located. I cleared several times my temp folder with ClearTemp.cmd, also Purge temporary files in my FME-script. But still I have problem with temp-file! Can you guide me how can I fix the problem? Thanks I can read my file via Reader and there is not any problem, but when I read it via FeatureReader, I have problem with temp file!
I am in the process of creating an FME script to download photos as attachments features in ArcGIS Portal using the FME ArcGIS Portal Feature Service.The script runs fine from the ArcGIS Pro application using the interoperability extension.The only problem is that images from all the features is downloaded, even if only some is selected in ArcGIS Pro.
Hello I am a GIS analyst and I want to learn FME for the first time. I checked different parts of the website but still don't know completely how to start to learn here!
I have yet to successfully use dates as an axis in ChartGenerator. Ideally, I would like to be able to use more natural date formats e.g. %B %Y or %m %Y and set the scale accordingly based upon time increments. Is this possible (in Chart Generator or another transformer) ? Or am I going to need to take it out into PowerBI, Excel, etc?
I have a dataset from a spreadsheet that i have created a counter for each row successfully. The SQL table i am importing this dataset into has a primary key (highlighted). This primary key is not recorded anywhere in the database as a sequence number. I have added in a statisticsCaculator transformer to obtain the max number. I want to insert each row from my dataset (first screenshot) but i want to insert the LUPID as count + LUPID.max. so i end up with 1691+1 = 1692, 1691+2 = 1693, 1691+3 = 1694 etc for each row what transformer would i use to do this?
Solved with LISP (.lsp) and csv export. Read my last post I working on a script that need to test some parameters in a hundres of dwg files.Just to make it short. Autocad_layer_frozen and Autocad_layer_description are two attribute that I need to check and what I use in this example. However, the only way I have succeeded so far to get empty layers visible is to use a dwg reader and choose individual file types. B No data of course. Nothing is read since the layer is empty. Both DWG reader and feature reader can only read layers that are not empty. Feature reader and with format "Any schema" can read all layers, also empty layers, but does not contain the native autocad attributes like Autocad_layer_frozen and Autocad_layer_description. Is there any way to read empty layers to get all the attributes that exist in a autocad layer feature with only use of FME?
I'm wondering how to use the Python Caller transformer to run the arcpy.RepairGeometry_management geoprocessing tool. I'm working with some input File Geodatabase data that's getting re-projected and producing self-intersections. The Geometry Validator transformer is identifying these but not repairing them (i.e. they come out the Failed port, not the Repaired port). I confirmed that using ArcGIS Geoprocessing tools on the same machine fixes the self-intersections, so I wanted to use the Python Caller to do the exact same thing in the context of the FME Workspace. What I'm getting is a generic error though, see below. Maybe my syntax is incorrect but I've tried a few different ways and haven't had success. Any help would be appreciated! Python Syntax:import fmeimport fmeobjectsimport arcpy # Template Function interface:# When using this function, make sure its name is set as the value of# the 'Class or Function to Process Features' transformer parameter
I have a query relating to raster analysis in FME Form using the RasterExpressionEvaluator I want to extract the maximum value of each pixel from a multiband raster, so for example if band 3 has the maximum value compared to bands 1 and 2 for a particular cell, only the value for band 3 for that pixel will be extracted and used in the resulting single band raster. The syntax I believe should work for this is as follows in the attached image but I cannot get it to work. The "maximum/max" functions are unavailable in the transformer and I am thinking that this logic not be usable on data of this type or within this transformer. Can anyone confirm if maximum syntax is workable on this transformer or even have another method of how to go about this? Thanks Andrew
Hi, I'm recently working on a workflow that creates a customs IFC property set and pushes it back to an IFC file. I have gone through all the materials I can find online but still encountered a problem. The GeometryPropertySetter successfully outputs the traits I intend to set (see column 1&2 in the attached image) but for some reason they can not be written in the IFC file. I can supply more info if required. Does anyone know what is causing this? Thanks a lot.
Hi, I have a workspace that write to SDE using a dynamic schema. The schema is build from an excel sheet where I have the name of the field, the type and the alias. I manage to write to SDE with all the correct parameter: attribute{0}nameattribute{0}.fme_data_typeattribute{0}.native_data_type The problem is that I cannot find a way to write alias. Anyone know if this is possible within a dynamic schema? thank you!
Given a call to a stored procedure like this:declare @return_value intexec @return_value = dbo.myProcedureHow do I re-assign @return_value to e.g. an attribute or a variable?