<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Identify feature class within feature dataset in Geoprocessing Questions</title>
    <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167974#M5633</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a list of feature class names I want to feed into a script, and one of the things I need the script to do is determine whether each feature class is held within a feature dataset (as then the script will treat the FC differently).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using Describe I can identify feature classes and feature datasets, however I cannot determine whether a FC is within a FD.&amp;nbsp; I can list children of a FD, but not parent of FC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there another way I can easily determine whether a specified FC is held in a FD?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The list of FCs is output from a third-party table, so doesn't reference feature datasets.&amp;nbsp; The FCs are contained in a database that has many feature datasets and hundreds of feature classes.&amp;nbsp; While I know I could Describe all the FDs in my database and compare the children to my list, I imagine this would take a long time, when my list only contains about 60 FDs and only about 15 of them are in FDs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EDIT: If possible I would like to determine the name of the Feature Dataset, not just if there is one.&amp;nbsp; Data is in a SDE Geodatabase (SQL Server)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;Mike.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Mike Louwrens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 01 Oct 2015 22:23:54 GMT</pubDate>
    <dc:creator>MikeLouwrens</dc:creator>
    <dc:date>2015-10-01T22:23:54Z</dc:date>
    <item>
      <title>Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167974#M5633</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a list of feature class names I want to feed into a script, and one of the things I need the script to do is determine whether each feature class is held within a feature dataset (as then the script will treat the FC differently).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using Describe I can identify feature classes and feature datasets, however I cannot determine whether a FC is within a FD.&amp;nbsp; I can list children of a FD, but not parent of FC.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there another way I can easily determine whether a specified FC is held in a FD?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The list of FCs is output from a third-party table, so doesn't reference feature datasets.&amp;nbsp; The FCs are contained in a database that has many feature datasets and hundreds of feature classes.&amp;nbsp; While I know I could Describe all the FDs in my database and compare the children to my list, I imagine this would take a long time, when my list only contains about 60 FDs and only about 15 of them are in FDs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EDIT: If possible I would like to determine the name of the Feature Dataset, not just if there is one.&amp;nbsp; Data is in a SDE Geodatabase (SQL Server)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR /&gt;Mike.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Mike Louwrens&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Oct 2015 22:23:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167974#M5633</guid>
      <dc:creator>MikeLouwrens</dc:creator>
      <dc:date>2015-10-01T22:23:54Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167975#M5634</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You can &lt;A href="http://resources.arcgis.com/EN/HELP/MAIN/10.1/index.html#/ListFeatureClasses/018v00000018000000/"&gt;list feature classes&lt;/A&gt; in your gdb. This won't go into feature datasets. If it's in the list, it isn't in a feature dataset. If it's not in the list, presumably it is in a feature dataset (or doesn't exist).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please elaborate if this doesn't address your issue.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 01 Oct 2015 22:33:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167975#M5634</guid>
      <dc:creator>DarrenWiens2</dc:creator>
      <dc:date>2015-10-01T22:33:52Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167976#M5635</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Could you provide a little more detail on how you're using the describe object against the feature classes? I would assume if you're to the point where you can describe the feature class you could also grab the path to the feature class on disk and check against it. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Oct 2015 00:01:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167976#M5635</guid>
      <dc:creator>FreddieGibson</dc:creator>
      <dc:date>2015-10-02T00:01:58Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167977#M5636</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;Freddie Gibson:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Could you provide a little more detail on how you're using the describe object against the feature classes? I would assume if you're to the point where you can describe the feature class you could also grab the path to the feature class on disk and check against it. &lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Currently I'm not really using the describe other than testing ways to get the FD.&amp;nbsp; The data is in a SDE geodatabase so when I have tried using describe to get a path, no FD is ever listed (maybe I'm doing this wrong?)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a describe option that would tell me the full path including the FD?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Mike.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Oct 2015 18:27:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167977#M5636</guid>
      <dc:creator>MikeLouwrens</dc:creator>
      <dc:date>2015-10-02T18:27:09Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167978#M5637</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;Freddie Gibson:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can &lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=http%3A%2F%2Fresources.arcgis.com%2FEN%2FHELP%2FMAIN%2F10.1%2Findex.html%23%2FListFeatureClasses%2F018v00000018000000%2F" rel="nofollow" target="_blank"&gt;list feature classes&lt;/A&gt; in your gdb. This won't go into feature datasets. If it's in the list, it isn't in a feature dataset. If it's not in the list, presumably it is in a feature dataset (or doesn't exist).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please elaborate if this doesn't address your issue.&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;That might work, although not ideal.&amp;nbsp; I should probably have said in my original post that I'd like to know which FD the FC is in.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Mike.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Oct 2015 18:28:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167978#M5637</guid>
      <dc:creator>MikeLouwrens</dc:creator>
      <dc:date>2015-10-02T18:28:51Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167979#M5638</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm unclear how you can describe a feature class and not know its path. The path tells you if it's in a feature dataset. Isn't this the case in SDE feature classes (obviously, I don't use SDE)?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 02 Oct 2015 19:39:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167979#M5638</guid>
      <dc:creator>DarrenWiens2</dc:creator>
      <dc:date>2015-10-02T19:39:16Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167980#M5639</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import arcpy,os
fc = "your file"
h,n = os.path.split(fc)
desc = arcpy.Describe(h)
print desc.datasetType
print desc.name&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 08:44:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167980#M5639</guid>
      <dc:creator>WesMiller</dc:creator>
      <dc:date>2021-12-11T08:44:55Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167981#M5640</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Could you upload some of your code so I can get a better picture of what you're doing? For the most part whether you're working in an enterprise geodatabase or a local geodatabase (i.e. file or person) the workflow shouldn't differ. In order to use the describe object you'd need to have a reference to the dataset, whether it be the direct path to it or a layer that points to the data. That's why I'm a little confused on getting the path if you're able to get to this point. Hopefully by looking at your logic will help me fill in some of the blanks so that we can give you a solid answer for this.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 03 Oct 2015 17:58:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167981#M5640</guid>
      <dc:creator>FreddieGibson</dc:creator>
      <dc:date>2015-10-03T17:58:53Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167982#M5641</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Freddie,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sorry I currently don't really have any code - first thing I was trying to do was get Describe or something to identify the FD a FC was in, if any, so haven't actually written the script yet.&amp;nbsp; I can send you the few lines of different Describe options I have tried, but so far none of them have told me which FD the FC is in.&amp;nbsp; I'll be back in the office tomorrow, so will post that then.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;MIke.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 04 Oct 2015 04:44:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167982#M5641</guid>
      <dc:creator>MikeLouwrens</dc:creator>
      <dc:date>2015-10-04T04:44:39Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167983#M5642</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Attached is all my code so far - have only attempted to find the Feature Dataset for the feature class so far, so not much to it.&amp;nbsp; Using the help from &lt;A href="http://desktop.arcgis.com/en/desktop/latest/analyze/arcpy-functions/describe-object-properties.htm" title="http://desktop.arcgis.com/en/desktop/latest/analyze/arcpy-functions/describe-object-properties.htm" rel="nofollow noopener noreferrer" target="_blank"&gt;Describe object properties—Help | ArcGIS for Desktop&lt;/A&gt; (and some of the other Describe Properties that appear to fit)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import arcpy, os

SDEDatabase = "Database Connections\\GISDatabase.sde"

## SWServiceLine is a Feature Class contained in a Feature Dataset called "StormWater",
## however my list of &lt;SPAN style="color: rgba(0, 0, 0, 0); font-family: Consolas, 'Courier New', Courier, mono, serif; font-size: 12px;"&gt;Feature &lt;SPAN style="color: rgba(0, 0, 0, 0); font-family: Consolas, 'Courier New', Courier, mono, serif; font-size: 12px;"&gt;Class&lt;/SPAN&gt;&lt;/SPAN&gt;es does not (and can not) identify if a particular 
## &lt;SPAN style="color: rgba(0, 0, 0, 0); font-family: Consolas, 'Courier New', Courier, mono, serif; font-size: 12px;"&gt;Feature &lt;SPAN style="color: rgba(0, 0, 0, 0); font-family: Consolas, 'Courier New', Courier, mono, serif; font-size: 12px;"&gt;Class&lt;/SPAN&gt;&lt;/SPAN&gt; is within a Feature Dataset and the name of the Feature Dataset if relevant
fc = SDEDatabase + "\\SWServiceLine"
tester = arcpy.Describe(fc)

## Describe options from ArcGIS desktop help.&amp;nbsp; Potentially there is one that
## tells me the Feature Dataset that contains the Feature Class, but
## I haven't found one yet
if hasattr(tester, "name"):
&amp;nbsp; print "Name:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; " + tester.name
if hasattr(tester, "dataElementType"):
&amp;nbsp; print "dataElementType:&amp;nbsp;&amp;nbsp;&amp;nbsp; " + tester.dataElementType
if hasattr(tester, "catalogPath"):
&amp;nbsp; print "CatalogPath:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; " + tester.catalogPath
if hasattr(tester, "Path"):
&amp;nbsp; print "Path:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; " + tester.path
if hasattr(tester, "datasetType"):
&amp;nbsp; print "DatasetType:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; " + tester.datasetType
if hasattr(tester, "baseName"):
&amp;nbsp; print "BaseName:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; " + tester.baseName

## As suggested by Wes Miller
h, n = os.path.split(fc)
desc = arcpy.Describe(h)
#print desc.datasetType&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ## this produces an error
print desc.name&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've been through a lot of the describe properties, but so far I haven't found any that tell me a) if the feature class is in a feature dataset or b) the name of the feature dataset.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Mike.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 08:44:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167983#M5642</guid>
      <dc:creator>MikeLouwrens</dc:creator>
      <dc:date>2021-12-11T08:44:58Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167984#M5643</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;Darren Wiens:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm unclear how you can describe a feature class and not know its path. The path tells you if it's in a feature dataset. Isn't this the case in SDE feature classes (obviously, I don't use SDE)?&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Hi Darren,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You don't need to specify the Feature Dataset in a path to a Feature Class (works the same way in a file/personal geodatabase as in SDE).&amp;nbsp; So as a result I can script things to happen to those feature classes without referring to the feature dataset at all.&amp;nbsp; However in this case I need to know which Feature Dataset contains each Feature Class, if any.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Mike.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 04 Oct 2015 19:49:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167984#M5643</guid>
      <dc:creator>MikeLouwrens</dc:creator>
      <dc:date>2015-10-04T19:49:40Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167985#M5644</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I stand corrected. I didn't realize you could refer to a feature class in a dataset without including the dataset in the path.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think you're going to have to resort to something like &lt;A href="http://resources.arcgis.com/EN/HELP/MAIN/10.1/index.html#//018w00000023000000"&gt;arcpy.da.Walk()&lt;/A&gt; to find your feature class and the containing feature dataset, but I may be missing something else.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 05 Oct 2015 05:45:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167985#M5644</guid>
      <dc:creator>DarrenWiens2</dc:creator>
      <dc:date>2015-10-05T05:45:48Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167986#M5645</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I had a quick look at this and I *think* &lt;A href="https://community.esri.com/migrated-users/19932" target="_blank"&gt;Darren Wiens&lt;/A&gt;​ is right, arcpy.da.Walk (or a combination of arcpy.ListDatasets() and arcpy.ListFeatureClasses() etc.) is the only way to get the Feature Dataset name if you only know the Feature Class name at runtime:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Something like:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import arcpy,os
gdb = r"C:\Temp\Default.gdb"
fcs = ["TESTFC",&amp;nbsp;&amp;nbsp; # standalone FC
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "TESTFDFC"] # FC in a feature dataset

def get_paths(path):
&amp;nbsp;&amp;nbsp;&amp;nbsp; """Use this if you have multiple FCs to check"""
&amp;nbsp;&amp;nbsp;&amp;nbsp; paths = {}
&amp;nbsp;&amp;nbsp;&amp;nbsp; for dirname,subdirs,files in arcpy.da.Walk(path):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; paths.update(zip(files, [os.path.basename(dirname.replace(path,""))]*len(files)))
&amp;nbsp;&amp;nbsp;&amp;nbsp; return paths

def get_fd(fc):
&amp;nbsp;&amp;nbsp;&amp;nbsp; """Use this if you only have one FC to check"""
&amp;nbsp;&amp;nbsp;&amp;nbsp; path = os.path.normpath(os.path.dirname(fc))
&amp;nbsp;&amp;nbsp;&amp;nbsp; if&amp;nbsp; path == ".":
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; path = arcpy.env.workspace
&amp;nbsp;&amp;nbsp;&amp;nbsp; for dirname,subdirs,files in arcpy.da.Walk(path):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if fc in files:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return os.path.basename(dirname.replace(path,""))

arcpy.env.workspace = gdb
paths = get_paths(gdb)
for fc in fcs:
&amp;nbsp;&amp;nbsp;&amp;nbsp; print os.path.join(paths[fc], fc)
&amp;nbsp;&amp;nbsp;&amp;nbsp; print os.path.join(get_fd(fc), fc)&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;TESTFC&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;TESTFC&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;TESTFD\TESTFDFC&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;TESTFD\TESTFDFC&lt;/SPAN&gt;&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 08:45:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167986#M5645</guid>
      <dc:creator>Luke_Pinner</dc:creator>
      <dc:date>2021-12-11T08:45:00Z</dc:date>
    </item>
    <item>
      <title>Re: Identify feature class within feature dataset</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167987#M5646</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;at least within the sql tables, the gdb_items indicates the Name, and the Path which contains the fds address if it applies...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="183712" alt="gdb_items.jpg" class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/183712_gdb_items.jpg" style="width: 620px; height: 291px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The gdb_itemrelationships would be more detailed, but as I understand, this might be enough, perhaps?&lt;/P&gt;&lt;P&gt;This was a helpful link in identifying this...&lt;/P&gt;&lt;P&gt;&lt;A href="http://desktop.arcgis.com/en/arcmap/10.3/manage-data/gdbs-in-sql-server/feature-dataset-storage-sqlserver.htm" title="http://desktop.arcgis.com/en/arcmap/10.3/manage-data/gdbs-in-sql-server/feature-dataset-storage-sqlserver.htm"&gt;Feature datasets in a geodatabase in SQL Server—Help | ArcGIS for Desktop&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Feb 2016 01:54:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/identify-feature-class-within-feature-dataset/m-p/167987#M5646</guid>
      <dc:creator>KevinMorrissey</dc:creator>
      <dc:date>2016-02-18T01:54:42Z</dc:date>
    </item>
  </channel>
</rss>

