Skip to content

Commit

Permalink
[TASK] Replace "t3-function-numrows" with "confval"
Browse files Browse the repository at this point in the history
This is a preparation for switching to PHP-based documentation rendering.

Additionally:
- Indentations are adjusted
- Role sql is used where appropriate

Releases: main, 12.4
  • Loading branch information
brotkrueml authored and github-actions[bot] committed Mar 1, 2024
1 parent fbac599 commit bcf85e0
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 18 deletions.
35 changes: 18 additions & 17 deletions Documentation/Functions/Numrows.rst
Original file line number Diff line number Diff line change
@@ -1,57 +1,58 @@
.. include:: /Includes.rst.txt
.. index::
Functions; numRows
Database; count
.. _numrows:
.. include:: /Includes.rst.txt
.. index::
Functions; numRows
Database; count
.. _numrows:

=======
numRows
=======

This object allows you to specify a SELECT query, which will be
This object allows you to specify a :sql:`SELECT` query, which will be
executed in the database. The object then returns the number of
rows, which were returned by the query.

.. contents::
:local:
.. contents::
:local:

.. index:: _numRows; Properties
.. _numRows-properties:
.. index:: _numRows; Properties
.. _numRows-properties:

Properties
==========

.. _numrows-table:
.. _numrows-table:

table
-----

.. t3-function-numrows:: table
.. confval:: table

:Data type: Table name

Name of the database table to query.

.. _numrows-select:
.. _numrows-select:

select
------

.. t3-function-numrows:: select
.. confval:: select

:Data type: :ref:`select`

Select query for the operation.

The sub-property :typoscript:`selectFields` is overridden internally with
:php:`count(*)`.
:sql:`count(*)`.

.. _numRows-examples:
.. _numRows-examples:

Example
=======

Get the number of content elements within certain colPos of the current page.
Get the number of content elements within certain :sql:`colPos` of the current
page.

.. code-block:: typoscript
:caption: EXT:site_package/Configuration/TypoScript/setup.typoscript
Expand Down
1 change: 0 additions & 1 deletion Documentation/Settings.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ use_opensearch =

[sphinx_object_types_to_add]

t3-function-numrows = t3-function-numrows // t3-function-numrows // Function numRows
t3-function-parsefunc = t3-function-parsefunc // t3-function-parsefunc // Function parseFunc
t3-function-replacement = t3-function-replacement // t3-function-replacement // Function replacement
t3-function-round = t3-function-round // t3-function-round // Function round
Expand Down

0 comments on commit bcf85e0

Please sign in to comment.