Como gerar relatórios e exportar para xls/csv?

@eduardo has asked:

Is it possible to export a table to xls?

To export data, just create a report with the information you would like to see! For this, access the Reports area (if it’s not in the menu, just press (CMD + K) or (CTRL + k) or click on the “Jump in” option next to Tabs on the left menu , then click on “see all tabs” and search for Reports. It’s this one:


Para exportar uma tabela, é só criar um relatório com as informações que você gostaria de ver!Basta acessar a área de Relatórios (se não estiver no menu, basta apertar a tecla (A) ou clicar nos três pontinhos ao lado de Tabs, ver todas as abas e pesquisar por Relatórios/Reports). É essa aqui:

3 Likes

@marcos.figueiredo @dammon.burden About that, it is possible to export these data automaticaly every day or other period? Could be with lowCode or something.

Hey @vinimenezes

It’s not possible to activate the Reports via lowcode, but you can create your own files if you know how to format them. For example, I created these two tables:

And using the following code, I was able to create a .csv file that brings me all the Active records from the first table.

$search = Jestor.loadData('customreports',['where' => ['status' => 'Active']]);
$report = "";
$headers = json_decode($search[0],true);
foreach($headers as $header => $value){
    $report = $report.$header.",";
}
$report = $report."\n";
foreach($search as $record){
    $record = json_decode($record,true);
    foreach($record as $fields){
        $report = $report.$fields.",";
    }
    $report = $report."\n";
}
$file = Jestor.createNewFile($report,"csv");
$objectNew['file'] = $file;

Then I can open this .csv in Excel.

So you could have a scheduled trick running a function that assembles these reports. It can be harder for other formats such as .xlsx, though.

1 Like

@fernando.nakandakari Ok, Thanks!

1 Like

With this new interface, how to create a new report?

1 Like

Hey @jean

To export data, just create a report with the information you would like to see! For this, access the Reports area clicking on the Jump in bar or pressing (CMD + K) or (CTRL + k) and search for reports ou relatórios
image

2 Likes

Atualizando, agora você consegue acessar os relatórios diretamente pela seção do connector no seu menu esquerdo.

Aqui está a nossa documentação: Reports

1 Like

Olá @Vitor_NoCoder

Quando eu clico para baixar em XLSX, para onde vai o arquivo baixado?

EDIT: Já vi que vai para o email

1 Like

Oi @cleiton.almeida

Voce pode baixar o relatorio indo na seção de notificações e la estará o do relatorio tambem. Só clicar na notificacao que ele será baixado

2 Likes

Top, não sabia dessa parte de relatórios! =D :writing_hand:

1 Like

Estou tentando exportar uma tabela para XLS.
No entanto, quando o processo é concluído e eu clico na notificação para obter o arquivo, recebo a seguinte mensagem:

{“status”:false,“data”:{“message”:“Request to /uploads/reports/Cadastro-de-Veiculos__ae0bde31256d153e678bcd22836ebab8.xlsx?download=1 (requested from ) is missing autentication. Token: ApiToken: “,“url”:”/uploads/reports/Cadastro-de-Veiculos__ae0bde31256d153e678bcd22836ebab8.xlsx?download=1”,“code”:401},“metadata”:{“response”:"Request to /uploads/reports/Cadastro-de-Veiculos__ae0bde31256d153e678bcd22836ebab8.xlsx?download=1 (requested from ) is missing autentication. Token: ApiToken: ",“message”:"Request to /uploads/reports/Cadastro-de-Veiculos__ae0bde31256d153e678bcd22836ebab8.xlsx?download=1 (requested from ) is missing autentication. Token: ApiToken: ",“org”:“oficinasoldera”,“notifications”:}}

Podem me ajudar?

Oi @cleiton.almeida

Faz um teste saindo da conta e fazendo login novamente e depois tenta gerar o relatorio novamente por favor

Foi @Vitor_NoCoder !

Valeu!

1 Like