Using transformers to modify data.
Recently active
Hi, I am looking for advice how to turn a JSON file into a JSON LD (linked data) with FME.This is an example of a JSON LD formathttps://json-ld.org/spec/latest/json-ld-framing/#example-3-flattened-library-objects There are 2 parts:1) @context: where you place the link to the complete vocabulary of the model2) @graph: where the features are written.How can I introduce these 2 parts when writing JSON in FME?Jasper
I am trying to figure out how to create map tiles along a route where the tiles have a certain amount of overlap, something similar to strip map index but not with rotating map view.
Hi there, I am calculating four attributes related to date using attribute creator and then I use Datefromatter to convert those attributes into the desired format (i.e. %y%m%d). When I write those attributes into CSV file, I found that the cell format of those attributes is still 'General'. It didn't change to the date format. Could anyone guide me on how to fix the issue?
I have a simple workspace that converts shapefile contours to CAD (dwg). When I create this workspace I specify which I field from my shapefile will be used to make it 3D (using the 3D forcer) and also which field I will use to define the Layers in the CAD file. These fields will be the same. I'm converting my workspace to a template so my non GIS/FME guys can do the conversions themselves. I have my input and output parameters created but I'm not sure how to create a parameter where a user can specify the field from the shapefile. Can something like this be done in FME?Here is my workspace:I'd like the user to be able to select the field from a drop down when they hit run:
I am trying to export data from SQL to CMDM Geodatabase. 200 values got truncated. I changed some of the attribute widths in CMDM, and truncated values decreased to 4. Instead of trying to check each attribute manually, is there any way to find these values directly?
I want use cyan Circle clipper Pipeline diagram?but I want to keep red section,how Ishoud do?
How create dim like this ? Can provide detailed steps?
Hi there,I am calculating the current and previous regulatory start and end years dates. For instance, the regulatory year starts from first May of every year and ends on the last day of April next year. So for the current year regulatory year period would be from 1-05-2019 to 30-04-2020. For the previous year, it would be 1-05-2018 to 30-04-2019. I am using following code to calculate the start and end of the year:Current Year Start : @DateTimeFormat(@DateTimeAdd(@DateTimeNow(),-P8M),%B %Y)Current Year End: @DateTimeFormat(@DateTimeAdd(@DateTimeNow(),P3M),%B %Y)Previous Year Start: @DateTimeFormat(@DateTimeAdd(@DateTimeNow(),-P20M),%B %Y)Previous Year End: @DateTimeFormat(@DateTimeAdd(@DateTimeNow(),-P9M),%B %Y) With the above code, the day is missing. If I use %d, it starts the day with reference to the current day. I don't know how to get the end or start day of the calculated months. So I decided to concatenate the hardcoded day with the above calculated months. The problem I a
Hi, I have been trying to figure out how to correct reproject from UTM to Ground. I have many datasets in an SDE environment (WKID: 26910) that I want to convert to Autocad DWG format so the engineers can use the data without shifting to local reference points.Dataset Coordinate System:NAD_1983_UTM_Zone_10N WKID: 26910 Authority: EPSGProjection: Transverse_Mercator False_Easting: 500000.0 False_Northing: 0.0 Central_Meridian: -123.0 Scale_Factor: 0.9996 Latitude_Of_Origin: 0.0 Linear Unit: Meter (1.0)We have a trimble unit that GPS's in Ground with the following Projection settings:Zone Parameters:Zone Record: 10 North Zone Type: Transverse Mercator Origin Lat: 0 00'00.000" N Origin Lng: 123 00'00.00 W Origin North: 0.00 Origin East: 500,000.000 Origin Scale 0.9996000Project Azimuth: North Azimuth Coordinate Direction: North East Datum Parameters: Datum Name: Nad 1983 (Canada) Translation X: 0.000m Translation Y: 0.000m Translation Z: 0.000m Ellipse Parameters: Ellip
Hello I am looking for a way to remove zeroes from some attributes, but not all. 1) I have sliced up a string using the "AttributeSplitter" with delimiter "3s4s" 2) original data is 1234567 -> two new lists (list1: 123 & list2: 4567). 3) Sometimes list2 have 0 as the first character. I am looking for a way to delete this 0 without deleting values with four characters. Regards, Stig
So I'm usually fairly aggressive in large workspaces in keeping the in-workspace Schema tidy and as small as possible after running data through various Transformers that all like to add their own default Attributes and Lists etc.This trimming of the Attributes and Lists at mid-points through the Workspace is under the belief the passing features with unnecessary attributes and lists that are no longer required through the Workspace would cause overall significant performance penalties. This makes something like AttributeKeeper a very common Transformer in my large or data heavy projects.However, I find that using AttributeKeeper, AttributeManager and AttributeRemover all have their own overheads to run, and you could slow your Workspace down by using them too often (well so I believe anyway!) The question is: When and how often should you use these in large projects/workspaces? Is there a best practice in FME for getting a balance on these?
From the attribute above containing newlines, I'm trying to extract each line of coordinates into a list using a StringSearcher with regex: \\n.+°.+°.+\\nI don't want lines of text to be included in the list that are not coordinates, so the first line starting with "Buoy" would not be captured. It should also be noted that the lines that are not coordinates may contain a '°' symbol, such as "Range line at 186°". Because of this, my methodology consisted of matching any set of characters containing 2 '°' symbols that fall between two newlines.My example regex seems to close, but it is also capturing the first 2 numbers of the next string. How would I need to format my regex to avoid this?
Looking to do histogram matching. From research, the preference is to be in a color space with intensity, therefore HSV or YCbCr. I've tried RGB matching but on the darker sets of satellite images, it does not match well when its 'brightness' increases. Is there something I can do/use in FME to convert from RGB to HSV ? Can I do this in python? Read in a feature and output a HSV image?
Hello - sorry if this is a very basic question but I'm struggling to convert a JSON response that is received from an API in to tabular data.The response is sourced as per the following:I've included two objects (apologies if 'object' is not the correct term) in the following .txt:I would like to generate tabular data from this response - i.e. based on the attached file I would like a new row for each 'object' (denoted by the "OrganisationID" value) with a selection of the values within this 'object' as attributes on the row.I've read the JSON tutorials and have tried various combinations of JSONFlattener, JSONExtractor and JSONFragmenter but with no joy.I would be extremely grateful for any advice that anyone can offer. Thanks in advance, Matt
hello , i want to design with sql statement on fme .i have coordinate system on a city and i want to know which cables are over lapped the border . if the cables are over lapped the border then change the colour of this cable .please if someone can tell me how can i do it .i will be thankful for him .Thanks
Hi there, I am a newbie in FME. So please accept my apology if my question sounds stupid. I want to calculate the year of the particulars date on FME. For example, I want to calculate the year of 31st March of the current year and next year. Similarly, I want to calculate the year of 1st April for the current year, and the previous year. These calculate years along with dates would be stored in columns. Looking forward for your guidance.
I am trying to determine which transformers to use in FME that perform the same tasks in ArcGIS. (I am working with the 2015 version.) Two polygon layers representing parcels and elevation are intersected to form parcel elevations. ArcGIS dissolve: to aggregate duplicate Intervals based on the Parcel ID.Select by attribute and calculate field: to select specific Intervals and populate a corresponding field with the calculated acreage. Example with just one record: Intersected Table: Multiple duplicate intervals.PARCEL_IDINTERVALELEV_00to01ELEV_01to02ELEV_02to03ELEV_03to04ELEV_04to05SHAPE_LengthSHAPE_Area1773860530R0-1 571.095248.081773860530R0-1 39.8619.241773860530R1-2 1313.8614638.281773860530R1-2 180.3964.991773860530R2-3 2376.0439618.101773860530R2-3 627.33130.581773860530R2-3 165.69952.031773860530R3-4 1208.5411412.151773860530R3-4 179.2648.361773860530R3-4 168.57554.171773860530R4-5 54.1963.211773860530R4-5 139.79612.06 Dissolved Ta
I've got a workbench setup that uses a preset xml to Post using HTTP Caller and retrieve an ID, see below:This works successfully. What I'd like to do is use an external CSV or XLS to loop back around and format the XML Templater with the new data for the next Post. I can't work out how to do this. I have looked at using XML Updater, but not sure I'm doing it right. Can someone help?See below of how I've attempted this.
I was trying to use FeatureReader to read an online zipped shapefile and it failed with the messageShape Reader: Failed to open dataset 'https://ecos.fws.gov/docs/species/shapefiles/usfws_I02T_I01_Cavaticovelia_aaa_current_range.zip' which is neither an existing file nor directoryHere is one of the link I use. https://ecos.fws.gov/docs/species/shapefiles/usfws_I02T_I01_Cavaticovelia_aaa_current_range.zipBelow are the parameters I set for the FeatureReader.The regular Reader worked just fine for the link Can anyone help me troubleshoot this issue?Thank you.
I have created a workbench to request an ID with a fake XML. This works for one ID. I've now added in an xls and an attribute manager to attempt to edit the XML that requests the IDs to request multiple ID's. This will not work, it keeps rejecting it. My XML is set to:Rejection:Please help me get this working.
Hello,I have a point dataset, and the attributes within can be summarised as per below:Point_IDArea_IDCategory1 AAZ2AAZ3AAX4BBZ5BBX6BBX I want to extract one point per Area_ID (I don't mid which), but it must assigned the the category attribute with the highest count within that Area_ID.Therefore, form the table above for Area_ID 'A' I would want to extract points 1 or 2, and for AREA_ID 'B' points 5 or 6. Any ideas? Thanks,RB
Hi,I'm experiencing an issue with SystemCaller when publishing to FME Server (2019.2 - build 19801 - 64-bit))We're using a SystemCaller to execute a program (with some parameters supplied) which is stored on a shared network, and it works successfully on FME Desktop 2019.2 (same build number as the Server instance). The Server has access (read/write) to the same network location, but when the published workspace runs, it just stops at the SystemCaller Execution. No error, no falling over...it just hangs. We left it overnight, but it was still the same the next morning.Things we've tried, to narrow down the issue:Ran the script in SystemCaller on FME Desktop - it worked in around 30 secondsRan the same script in the cmd prompt on the Server box (as svc_fme user) - it ran successfully in 30 secondsTried hardcoding the network location into Server (rather than using $(FME_SHAREDRESOURCE_DATA)) - this didn't affect the outcome at all - still hungThere are additional '/&
Hi AllThis is not a question, but some feedback/tips on how I solved this issue - hopefully it will assist someone that had issues with a similar project as well. I was trying to create a dynamic html dashboard that reads a bunch of real time values from database records and then display them with labels in an HTML table, the order of the values, layout and structure of which I wanted to format to my liking. The HTMLReportGenerator transformer did not give me enough control as to what I wanted to do, so I ended up using the XMLTemplater.If you want to create an HTML page using the XMLTemplater, you may find that the HTML code does not always parse correctly when running your workspace (the HTML is evaluated to ensure it conforms to XML standards). The reason for this is that some of HTML tags were not properly opened or closed. Since my HTML was still very valid, a workaround for this is to comment out (using "<!--" and "-->") those pieces of HTML code used i
Dear FME'ers, I have a question about the conflict resolution of SQLExecutors and FeatureReaders.I found the issue when I was reading data from a PostgreSQL database. Some of the initiator's attribute names where the same as in the result of my SQL. Therefore I used the option 'conflict resolution'. This because I supposed that the data of the initiator is then overwritten by the data of the SQL script (for the attributes with conflicting names).After that I tried to rename the output attributes with the help of a BulkAttributeRenamer but got an error. This is not the case when I set the conflict resolution to 'Use Initiator'. There is also no problem when I use a regular AttributeRenamer If I'm obliged to remove all conflicting attributes then what is the use of the conflict resolution? Or is this a problem related to the BulkAttributeRenamer? In attachment an example of my question with some extra info. I was able to recreate the issue by reading an Excel
Hello all,I am trying to automate the output of GIS data from PostGIS to Autocad DWG. The base data is in geographic coordinates (lat / long) and I have been able to successfully create the output DWG in GDA2020 UTM Zone 52, 53 or 54.The problem is that the end users need the data in ground coordinates not grid but I am not sure how to define a custom projection to either take it from geographic to ground or from geographic to grid to ground.I have been able to find the formula for the scale factor but this is something that will change for each extract of the data. Does anyone have any advice on the best way to create a new projection on the fly using the newly defined scale factor?