Edit page in Livemark
(2023-01-25 11:55)

Integer Field

The field contains integers - that is whole numbers. Integer values are indicated in the standard way for any valid integer. Read more in Table Schema Standard.

Example

from frictionless import Schema, extract, fields

data = [['name'], ['1'], ['2'], ['3']]
rows = extract(data, schema=Schema(fields=[fields.IntegerField(name='name')]))
print(rows)
[{'name': 1}, {'name': 2}, {'name': 3}]

Reference

fields.IntegerField (class)

fields.IntegerField (class)

Field representation

Signature

(*, name: Optional[str] = None, title: Optional[str] = None, description: Optional[str] = None, format: str = default, missing_values: List[str] = NOTHING, constraints: dict = NOTHING, rdf_type: Optional[str] = None, example: Optional[str] = None, schema: Optional[Schema] = None, bare_number: bool = True) -> None

Parameters

  • name (Optional[str])
  • title (Optional[str])
  • description (Optional[str])
  • format (str)
  • missing_values (List[str])
  • constraints (dict)
  • rdf_type (Optional[str])
  • example (Optional[str])
  • schema (Optional[Schema])
  • bare_number (bool)

fields.integerField.bare_number (property)

It specifies that the value is a bare number. If true, the pattern to remove non digit character does not get applied and vice versa. The default value is True.

Signature

bool