Comments (6)
With the following query, you could just write "null" in the source_username field:
query = SELECT concat(destination_username, '@', destination_domain) as destinations FROM aliases WHERE source_username ='%u' and source_domain ='%d' and enabled = true UNION ALL SELECT concat(destination_username, '@', destination_domain) as destinations FROM aliases WHERE source_username = 'null' and source_domain ='%d' and enabled = true AND not exists (SELECT id FROM aliases WHERE source_username ='%u' and source_domain ='%d' and enabled = true);
But keep in mind that this way no user named null should exist.
This way you dont event need the source_username field to be null.
Hopes this helps you.
Fabian
from mailman.
@phiilu
I can confirm that the query of @hibas123 works as expected. Also, the identical query is given in the Questions and Answers section in Thomas Leister's official guide.
from mailman.
@soulsymphonies Thank you for using my GUI :)
I would suggest to go with @hibas123 solution (Thank you for helping out!). If the provided query is working I will add it to the docs, otherwise I want to collect more feedback before doing anything.
from mailman.
Thank you @lonkey!
I added a link to the guide, unfortunately this guide is only available in german. Maybe Thomas will also add it to the english version in the future.
from mailman.
thank you ever so much for all your efforts, sorry for the late reply, lot's of things happened in my life that I had to address.
I think this solution covers it. Thanks again.
from mailman.
i edited @hibas123 query to:
query = SELECT concat(destination_username, '@', destination_domain) as destinations FROM aliases WHERE source_username ='%u' and source_domain ='%d' and enabled = true UNION ALL SELECT concat(destination_username, '@', destination_domain) as destinations FROM aliases WHERE source_username = '*' and source_domain ='%d' and enabled = true AND not exists (SELECT id FROM aliases WHERE source_username ='%u' and source_domain ='%d' and enabled = true);
so you could just write "*" in the source_username field instant of "null"
from mailman.
Related Issues (20)
- several vmail admins HOT 1
- Login - Something went wrong HOT 2
- Client Ip log HOT 4
- zeigt keine Domains usw. an HOT 6
- Problems while installing HOT 1
- No Catchall ("Alias requires Username") HOT 2
- Login - Password
- MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled. HOT 3
- Userlogin Alias Problem HOT 2
- Password integrety problem HOT 1
- Problem with Database HOT 4
- Non-standard port for database HOT 1
- Error: Cannot read 'data' of undefined
- Support of unix socket for access to mysql/mariadb database
- Using unix socket and nginx as reverse proxy to access web server
- Aliases with NULL for Source-Adress causes Mailman to stop working HOT 2
- Vorschlag für Änderung
- Docker Reagiert nicht mehr nach neustart
- External Database Support HOT 1
- Attach not working [win10]
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 mailman.