PHPackages                             medlib/yaz - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Search &amp; Filtering](/categories/search)
4. /
5. medlib/yaz

ActiveLibrary[Search &amp; Filtering](/categories/search)

medlib/yaz
==========

Medlib is a searche Library

v2.2(9y ago)41682MITPHPPHP &gt;=5.5.9

Since Feb 4Pushed 9y ago4 watchersCompare

[ Source](https://github.com/medlib-v2/yaz)[ Packagist](https://packagist.org/packages/medlib/yaz)[ Docs](https://www.medlib.fr)[ RSS](/packages/medlib-yaz/feed)WikiDiscussions master Synced yesterday

READMEChangelog (3)Dependencies (5)Versions (4)Used By (0)

YAZ Query Builder
-----------------

[](#yaz-query-builder)

### Installation Laravel

[](#installation-laravel)

#### Dependencies

[](#dependencies)

[medlib/marcxml](https://github.com/medlib-v2/marcxml)

You can install this package by using [Composer](http://getcomposer.org), running this command:

```
    composer require medlib/yaz
```

The next required step is to add the service provider to config/app.php :

```
'providers' => [
    ...
    Medlib\Yaz\Providers\YazServiceProvider::class,
    Medlib\MarcXML\Providers\ParserServiceProvider::class,
]
```

```
'aliases' => [
    ...
    'Yaz' => Medlib\Yaz\Facades\Yaz::class,
    'Query' => Medlib\Yaz\Facades\Query::class,
    'MarcXML' => Medlib\MarcXML\Facades\MarcXML::class,
]
```

### Publish

[](#publish)

The last required step is to publish views and assets in your application with :

```
    php artisan vendor:publish
```

If you get the error

```
    Nothing to publish for tag []!
```

Then run this command :

```
    php artisan config:clear
```

### Examples

[](#examples)

- Request with a return type of `BibliographicRecord` (all records):

    ```
    use Medlib\Yaz\Query\YazQuery;

    $this->results = YazQuery::create()
    ->from('SUDOC')
    ->where('au="totok" and ti="Handbuch"')
    ->orderBy('au ASC')
    ->all();

    ```
- Request with a return type of `BibliographicRecord` (one record):

    ```
    use Medlib\Yaz\Query\YazQuery;

    $this->results = YazQuery::create()
    ->from('SUDOC')
    ->where('au="totok" and ti="Handbuch"')
    ->first();

    ```
- Request with a return type of `BibliographicRecord` (limit):

    ```
    use Medlib\Yaz\Query\YazQuery;

    $this->results = YazQuery::create()
    ->from('BNF')
    ->where('au="totok" and ti="Handbuch"')
    ->limit(0,10)
    ->all();

    ```
- Request with a return type of `string` (all records):

    ```
    use Medlib\Yaz\Query\YazQuery;
    use Medlib\Yaz\Record\YazRecords;

    $this->results = YazQuery::create()
    ->from('BNF')
    ->where('au="totok" and ti="Handbuch"')
    ->orderBy('au ASC')
    ->all(YazRecords::TYPE_STRING);

    ```
- Request with a return type of `xml` equal to `BibliographicRecord` (all records):

    ```
    use Medlib\Yaz\Query\YazQuery;
    use Medlib\Yaz\Record\YazRecords;

    $this->results = YazQuery::create()
    ->from('connection_name')
    ->where('au="totok" and ti="Handbuch"')
    ->orderBy('au ASC')
    ->all(YazRecords::TYPE_XML);

    ```

#### Allowed parameters

[](#allowed-parameters)

##### Type:

[](#type)

```
- TYPE_STRING
- TYPE_RAW
- TYPE_XML
- TYPE_SYNTAX
- TYPE_ARRAY

```

OrderDescriptionASCSort ascendingIASCSort ascending, Case insensitive sortingSASCSort ascending, Case sensitive sortingDESCSort descendingIDESCSort descending, Case insensitive sortingSDESCSort descending, Case sensitive sorting### Pagination

[](#pagination)

- Action:

    ```
    use Medlib\Yaz\Pagination\Paginator;
    use Medlib\Yaz\Record\YazRecords;

    $pagination = new Paginator('BNF', 10);

    $pagination->getQuery()
    ->where('au="totok"')
    ->orderBy('ti ASC');

    $pagination->setPage($request->get('page', 1));

    $pagination->render();

    ```
- Template:

    ```
      Count: echo $pagination->getNbResults();
      foreach($pagination->getResults(YazRecords::TYPE_STRING) AS $result):
            echo $result;
      endforeach;

    ```

### Required

[](#required)

- [YAZ Client 4|5](http://www.indexdata.dk/yaz/)
- [PHP YAZ](http://pecl.php.net/package/yaz)

Congratulations, you have successfully installed Yaz Query Builder !

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~29 days

Total

3

Last Release

3374d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/1168143?v=4)[Patrick Luzolo](/maintainers/eldorplus)[@eldorplus](https://github.com/eldorplus)

---

Top Contributors

[![eldorplus](https://avatars.githubusercontent.com/u/1168143?v=4)](https://github.com/eldorplus "eldorplus (5 commits)")

---

Tags

yazz-3950librarybibliothèquefinder bookssearch booksyazz3950

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/medlib-yaz/health.svg)

```
[![Health](https://phpackages.com/badges/medlib-yaz/health.svg)](https://phpackages.com/packages/medlib-yaz)
```

###  Alternatives

[awesome-nova/dependent-filter

Dependent filters for Laravel Nova

26190.2k](/packages/awesome-nova-dependent-filter)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
