Usina BRAdvPL Guide
Sign in
← All topics
ENTRY POINTUnder review

F290OWN

User Function F290OWN()

Adds an FINA290 IndRegua filter and replaces the standard issue-date criterion.

F290OWNFINA290
01 · OVERVIEW

Overview

The specific documentation allows an additional filter in payable invoice IndRegua. Entry point presence removes the standard issue-date filter while keeping the other standard criteria. Returning an empty string therefore does not establish that the complete original filter is preserved. The page identifies SIGAFIN, FINA290 and Brazil, with no parameters. (TOTVS, ref. 1) The P12.2210 listing concatenates the result to cFiltro in FA290CHECF. (Ref. 2)

02 · SYNTAX

Syntax

User Function F290OWN()

Return value

Character expression added to the IndRegua filter. The official example concatenates conditions beginning with .AND. (Ref. 1)

03 · PRACTICAL EXAMPLE

Limit issue dates to the environment base date

#Include "Protheus.ch"

User Function F290OWN()
    // Adapted from the official example (ref. 1); does not query or write records.
    Local cFilter := ""
    // Entry point presence removes the standard issue-date criterion.
    // dDataBase belongs to the Protheus context and is not translated.
    cFilter += '.AND.DTOS(E2_EMISSAO)>="' + DToS(dDataBase) + '"'
    cFilter += '.AND.DTOS(E2_EMISSAO)<="' + DToS(dDataBase) + '"'
Return cFilter
Expected result

Proposes issue-date limits equal to the base date. Other standard criteria remain subject to routine processing. Example not compiled or run in Protheus.

BEST PRACTICES
  • The return is an AdvPL expression used by the IndRegua filter; do not treat it as an SQL fragment.
  • Do not return .T. or .F. instead of filter text. The official parameter section states that there are no parameters.
  • The example limits issue dates to one day. Using a range requires an explicit rule and date validation.
  • Compare displayed records with and without the entry point, including dates equal to and outside the base date. Issue date and due date are different criteria.
  • Editorial test plan: compare standard and customized behavior in the described operations, inspect resulting records and record release and patch.
  • Under review: sources and example checked against documentation; code not compiled or run in Protheus. Exact transaction position and target release behavior remain unconfirmed.

Related content

REFERENCES
  1. TOTVS. F290OWN - Filtro complementar na Indregua. TDN. Accessed on 2026-10-23.
  2. EURAI. Pontos de Entrada P12.2210 - Parte 2. Universo do Desenvolvedor, 2023. Accessed on 2026-10-23.
Status
Under review
Page created on
Last reviewed on
Original language
Portuguese
Reviewed by
Usina.BR

Was this content helpful?

👍 Like 0👎 Dislike 0

Sign in to rate this article.

0 approved comment(s)

Comments

There are no approved comments yet.

Sign in with Google or Microsoft to comment.

Powered by Usina Docs · Alpha