Comments (9)
Yes, it is a bug. I am working on fixing it.
from core.
@Ainschy can you check this?
from core.
related with #880
from core.
The issue also exits in MetaModels 2.3.
Given SQL
SELECT * FROM mm_region
WHERE IF (
{{param::get?name=act}} = 'edit',
(
pid = (
SELECT unterkunft_region_land
FROM mm_unterkunft
WHERE
id=SUBSTRING_INDEX( {{param::get?name=id}} ,'::',-1)
)
),
(
pid != ''
)
)
Result after CustomSQL
breaks it:
SELECT * FROM mm_region
WHERE IF (
NULL = 'edit',
(
pid = (
SELECT unterkunft_region_land
FROM mm_unterkunft
WHERE
id=SUBSTRING_INDEX(NULL{{,'::',-1)
)
),
(
pid != ''
)
)
}}
from core.
When no default value is defined, the answer is NULL
{{param::get?name=category&default=defaultcat}}
from core.
When no default value is defined, the answer is NULL
{{param::get?name=category&default=defaultcat}}
@baumannsven implemented this once - unfortunately I can no longer say exactly why... before it was an empty string
from core.
This was to allow for null
. If you want an empty string, you should use an empty default AFAIR.
from core.
After discussion with @dmolineus:
Given SQL
SELECT * FROM mm_region
WHERE IF (
{{param::get?name=act}} = 'edit',
(
pid = (
SELECT unterkunft_region_land
FROM mm_unterkunft
WHERE
id=SUBSTRING_INDEX( {{param::get?name=id}} ,'::',-1)
)
),
(
pid != ''
)
)
The expected Result is (green=expected;red=incorrectly generated)
SELECT * FROM mm_region
WHERE IF (
NULL = 'edit',
(
pid = (
SELECT unterkunft_region_land
FROM mm_unterkunft
WHERE
+ id=SUBSTRING_INDEX(NULL,'::',-1)
- id=SUBSTRING_INDEX(NULL{{,'::',-1)
)
),
(
pid != ''
)
)
-}}
from core.
Fixed with #1496
from core.
Related Issues (20)
- ensure jumpTo page ID is integer HOT 1
- Add id and tstamp at BE sorting HOT 1
- Indexierung bei mehreren Domains HOT 1
- Change runonce.php to migrations
- contao 4.13 and 5? HOT 3
- Change 'dataContainer' to '\ContaoCommunityAlliance\DcGeneral\DC\General::class' HOT 1
- Veröffentlichter Übersetzungsstatus greift nicht im Filter HOT 2
- Pagination does not include limit in calculation HOT 1
- Faulty routing when legacy_routing is switched off HOT 1
- Paginierung mit GET in Verbindung mit Filter HOT 2
- Aufbau des Suchindexes seit Contao 4.9 mit MM 2.2 aufgrund vieler MMs, Filter und Seiten nicht möglich HOT 10
- [2.3] Broken filter url builder HOT 1
- Get parameter array handled incorrectly HOT 2
- bei Eingabefeldern HTML-Attribut maxlenght aufgrund der SQL-Feldgröße setzen
- Referenced Meta Models with brackets ( ... ) can not be chosen (Error: did not accept the value) HOT 10
- Checked with PHPCQ MM 2.3 Repos (ready for release)
- Ansichtsbedingungen des Eingabefeldes über einen Filter ansprechen HOT 3
- Hide the button for copying metamodel
- Error 500 is key "language" at filter rule select HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from core.