Question: I know that we can use SPOOL command to export query result in CSV format from sql developer. However, I would like to export the query result as xlsx format instead of CSV format. Is there any command that I can use ??

Answer: 
You don't reload table view in `fallQuarterCell`. 

`let vc = fallQuarterCell()` creates a new cell. Your collection view doesn't contain it, so `vc.tableView.reloadData()` does nothing.

When you use `collectionView.dequeueReusableCell`, you may get the old cell, so you should reload the table view in this cell. You should read [documentation](https://developer.apple.com/documentation/uikit/uicollectionview/1618063-dequeuereusablecell):

> 
> Call this method from your data source object when asked to provide a
>  new cell for the collection view. This method dequeues an existing
>  cell if one is available or creates a new one
> 
> 
> 

For example, you can add `func updateViews()` in `fallQuarterCell`:

```
func updateViews() {
    tableView.reloadData()
}

```

And call it here:

```
if (indexPath.row == 0){
    let cell1 = collectionView.dequeueReusableCell(withReuseIdentifier: customCellIdentifier, for: indexPath) as! fallQuarterCell
    cell1.layer.borderColor = UIColor.orange.cgColor
    cell1.layer.borderWidth = 2
    cell1.layer.cornerRadius = 5
    cell1.quarters = self.quarters[0]
    cell1.updateViews()
    return cell1
}

```
All you have to do is create a separate cell class for collection view cell, and create an outlet of your table view into that cell class.

---

In your **cellForItemAt** method of the **collection view** do below code:

```
func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -> UICollectionViewCell {

let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "TabelCell", for: indexPath) as! MyTabelCell

cell.MyTableView.reloadData()

}

```

---

Now you have to **reload** collection view and it will automatically reload the table view. That's the best and easiest way to approach **TableView in CollectionView**