Download the PHP package los/uql without Composer

On this page you can find all versions of the php package los/uql. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package uql

UQL - Url Query language

Build Status Coverage Status Latest Stable Version Total Downloads License

This library utilizes url query parameters and generates db queries.

At this moment, it provides integration with:

Planned:

Installing

Usage

The builder uses the query parameters 'q' for the queries and 'h' for hint (sort, order, limits, etc). You can change these in the constructor:

The Select instance returned by the builder methods is a clone from the one passed in the constructor.

Zend DB

Passing the request directly:

or manually passing the parameters:

Examples:

operation url query select
equal ?q={"id":1} WHERE id = 1
not ?q={"id":{"$not":1}} WHERE id != 1
in ?q={"id":{"$in":[1,2]}} WHERE id IN (1, 2)
nin ?q={"id":{"$nin":[1,2]}} WHERE id NOT IN (1, 2)
like ?q={"name":{"$like":"John%"}} WHERE name LIKE 'John%'
null ?q={"$null":"name"} WHERE name IS NULL
not null ?q={"$nnull":"name"} WHERE name IS NOT NULL
and ?q={"$and":[{"id":1},{"name":"John"}]} WHERE id = 1 AND name = 'John'
or ?q={"$or":[{"id":1},{"name":"John"}]} WHERE id = 1 OR name = 'John'
greater ?q={"price":{"$gt":100}} WHERE price > 100
greater or equal ?q={"price":{"$gte":100}} WHERE price >= 100
less ?q={"price":{"$lt":100}} WHERE price < 100
less or equal ?q={"price":{"$lte":100}} WHERE price <= 100
between ?q={"price":{"$bt":[100,200]}} WHERE price >= 100 AND price <= 200

You can mix and nest queries:

url query select
?q={"id":{"$not":1},"$or":[{"id":2},{"id":"3"}],"$and":[{"id":2},{"name":"test"}]} WHERE "id" != '1' AND ("id" = '2' OR "id" = '3') AND ("id" = '2' AND "name" = 'test')
?q={"$or":[{"$and":[{"id":1},{"name":"test"}]},{"id":{"$not":1}},{"name":"test"}]} WHERE (("id" = '1' AND "name" = 'test') OR "id" != '1' OR "name" = 'test')

Hint examples:

operation url query select
sort ?q={"id":1}&h={"$sort":"name"} WHERE id = 1 ORDER BY name asc, price DESC
sort ?q={"id":1}&h={"$sort":{"name":"asc","price":-1}} WHERE id = 1 ORDER BY name asc, price DESC
limit ?q={}&h={"$limit":10} SELECT * FROM table LIMIT 10
limit + skip ?q={}&h={"$limit":10,"$skip":20} SELECT * FROM table LIMIT 10 SKIP 10

All versions of uql with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
psr/http-message Version ^1.0 || ^2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package los/uql contains the following files

Loading the files please wait ....