GithubHelp home page GithubHelp logo

cgohlke / fmkr Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 29 KB

Access FileMaker(tm) server databases

Home Page: https://pypi.org/project/fmkr

License: BSD 3-Clause "New" or "Revised" License

Python 100.00%
database filemaker python

fmkr's Introduction

Access FileMaker(tm) Server Databases

Fmkr is a Python library to access FileMaker(tm) Server 8 Advanced databases via the XML publishing interface.

"FileMaker" is a registered trademark of Claris International Inc.

Author:Christoph Gohlke
License:BSD 3-Clause
Version:2022.9.28

Requirements

This release has been tested with the following requirements and dependencies (other versions may work):

Revisions

2022.9.28

  • Convert docstrings to Google style with Sphinx directives.

2022.3.24

  • Add type hints.
  • Improve string representations of objects.
  • Add immutable sequence interface to FMPXMLResult.
  • Remove support for Python 3.6 and 3.7 (NEP 29).

2021.3.6

  • Update copyright and formatting.

2020.1.1

  • Remove support for Python 3.5.
  • Update copyright.

2018.8.15

  • Move fmkr.py into fmkr package.

2018.5.25

  • Use lxml instead of minidom to parse FMPXMLResult.
  • Improve string representations of FMPXMLResult and FMField.
  • Update error codes.
  • Remove support for Python 2.

2006.10.30

  • Initial release.

References

  1. http://www.filemaker.com/downloads/documentation/fmsa8_custom_web_guide.pdf

Examples

>>> from fmkr import FM, FMError
>>> fmi = FM('filemaker.domain.com', 80, 'http')
>>> fmi.set_db_data('database', 'layout', maxret=5)
>>> fmi.set_db_password('fmuser', 'password')
>>> # create a new record
>>> fmi.add_db_param('FIRST', 'John')
>>> fmi.add_db_param('LAST', 'Doe')
>>> fmi.fm_new()
>>> # find and sort records
>>> fmi.add_db_param('LAST', 'Doe', 'bw')
>>> fmi.add_sort_param('LAST', 'ascend', 1)
>>> fmi.add_sort_param('FIRST', 'ascend', 2)
>>> result = fmi.fm_find()
>>> for record in result:
...     print(record['FIRST'], record['LAST'])
John Doe
>>> # delete record
>>> recid = result[0]['RECORDID']
>>> fmi.set_record_id(recid)
>>> fmi.fm_delete()
>>> # catch an exception
>>> try:
...    fmi.add_db_param('LAST', 'Doe', 'cn')
...    fmi.fm_find()
... except FMError as exc:
...    print(exc)
FileMaker Error 401: No records match the request

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.