processing/src/main/java/org/apache/carbondata/processing/util/CarbonDataProcessorUtil.java
/**
   * This method will get the store location for the given path, segment id and partition id
   *
   * @return data directory path
   */
This method will get the store location for the given path, segment id and partition id
@return data directory path
This method will get the store location for the given path segment id and partition id @return data directory path
public static String checkAndCreateCarbonStoreLocation(String factStoreLocation,
      String databaseName, String tableName, String partitionId, String segmentId) {
    CarbonTable carbonTable = CarbonMetadata.getInstance().getCarbonTable(databaseName, tableName);
    CarbonTableIdentifier carbonTableIdentifier = carbonTable.getCarbonTableIdentifier();
    CarbonTablePath carbonTablePath =
        CarbonStorePath.getCarbonTablePath(factStoreLocation, carbonTableIdentifier);
    String carbonDataDirectoryPath =
        carbonTablePath.getCarbonDataDirectoryPath(partitionId, segmentId);
    CarbonUtil.checkAndCreateFolder(carbonDataDirectoryPath);
    return carbonDataDirectoryPath;
  }
public static String checkAndCreateCarbonStoreLocation ( String factStoreLocation , String databaseName , String tableName , String partitionId , String segmentId ) { CarbonTable carbonTable = CarbonMetadata . getInstance ( ) . getCarbonTable ( databaseName , tableName ) ; CarbonTableIdentifier carbonTableIdentifier = carbonTable . getCarbonTableIdentifier ( ) ; CarbonTablePath carbonTablePath = CarbonStorePath . getCarbonTablePath ( factStoreLocation , carbonTableIdentifier ) ; String carbonDataDirectoryPath = carbonTablePath . getCarbonDataDirectoryPath ( partitionId , segmentId ) ; CarbonUtil . checkAndCreateFolder ( carbonDataDirectoryPath ) ; return carbonDataDirectoryPath ; }
This method will get the store location for the given path, segment id and partition id
 @return data directory path
This method will get the store location for the given path segment id and partition id @return data directory path