© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
FilamentF
Filament•3y ago•
4 replies
WolfMoon

Filament Excel exporting table data

Hey everyone, i have a problem about the exporting data from table.

Here is my code:
    protected function getTableBulkActions(): array
    {
        return [
            ExportBulkAction::make()->exports([
                ExcelExport::make('Table Data')
                    ->fromTable()
                    ->askForFilename($this->getTablePluralModelLabel() . ' ' . now()->format('d-m-Y H:i:s'))
                ->withColumns([
                    Column::make('answers.entry.created_at')
                        ->heading('Ekleme Tarihi')
                        ->formatStateUsing(fn($record) =>
                        $record->answers->first()->entry->created_at->format('d-m-Y H:i:s')
                    )
                ])
            ])
        ];
    }
    protected function getTableBulkActions(): array
    {
        return [
            ExportBulkAction::make()->exports([
                ExcelExport::make('Table Data')
                    ->fromTable()
                    ->askForFilename($this->getTablePluralModelLabel() . ' ' . now()->format('d-m-Y H:i:s'))
                ->withColumns([
                    Column::make('answers.entry.created_at')
                        ->heading('Ekleme Tarihi')
                        ->formatStateUsing(fn($record) =>
                        $record->answers->first()->entry->created_at->format('d-m-Y H:i:s')
                    )
                ])
            ])
        ];
    }


It exports all columns with data but expect 2 column, and idk why its empty.

Here is that table columns coming empty:
                Tables\Columns\TextColumn::make('answers.value')
                    ->label('Yanıtlar')
                    ->searchable()
                    ->sortable(), 
                Tables\Columns\TextColumn::make('answers.value')
                    ->label('Yanıtlar')
                    ->searchable()
                    ->sortable(), 


This column not exported, i mean its coming empty in excel report.
Filament banner
FilamentJoin
A powerful open source UI framework for Laravel • Build and ship admin panels & apps fast with Livewire
20,307Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Filament Excel Export in Table Header
FilamentFFilament / ❓┊help
2y ago
Filament Excel Export
FilamentFFilament / ❓┊help
3y ago
format data in filament table
FilamentFFilament / ❓┊help
17mo ago