I’m stuck with something I thought should be straightforward. I need to create backup copies of existing feature classes hosted within an SDE. Backup copies will need going into a Feature Dataset ‘ss’ that sits inside the same SDE hosting the feature classes. FC1 will have fields ‘Field1’, ‘Field2’ and ‘Field3’, and FC2 will have fields ‘Field4’, ‘Field5’ and ‘Field6’. I can do this easy if I read and write these two feature classes as Individual Feature Types, however I was hoping for a more elegant way to do this with Single Merger Feature Types and a Dynamic Writer that would fan out the individual feature classes honouring their schemas. When I try this second approach, resulting FC1 backup copy will have its fields ‘Field1’, ‘Field2’ and ‘Field3’, but also ‘Field4’, ‘Field5’ and ‘Field6’ that have been transferred from FC2’s schema. Same goes for FC2 which will also have FC1’s fields on it. What am I doing wrong?
@d.jimenez Check your Schema Sources. Make sure you're not pulling from several sources and only using the Schema Feature. Perhaps on the dynamic reader feature type, make sure you remove all the source attributes that might be floating around from when you created the workspace. Can you attached a copy of your workspace?
@d.jimenez Check your Schema Sources. Make sure you're not pulling from several sources and only using the Schema Feature. Perhaps on the dynamic reader feature type, make sure you remove all the source attributes that might be floating around from when you created the workspace. Can you attached a copy of your workspace?
Thanks @Mark Stoakes. It won't run if Schema Sources set to "Schema From Schema Feature" returning below error:
Attached workspace for reference - thanks!
@d.jimenez Thanks for including the workspace. You don't have a schema feature. You only have the source dataset. So I think you might have to select the SDE Geodb reader as your schema and also Geometry From First Feature
@Mark Stoakes thanks! I think I figured it out, I saw elsewhere that 'Add Reader as Resource' was used to solve a similar query and it's worked great here also. The reader 'schema' will be added as a resource under 'Workspace resources' and this is the schema that has to be selected in the writer as 'Schema Source'. Selecting instead the SDE geodatabase reader as the schema source will result in each feature class having all the fields from all other feature classes as well which is what I'm trying to avoid. Thank you