sqlite iff要更改结果返回

发布于 2025-01-30 16:12:20 字数 180 浏览 2 评论 0原文

我正在查询一张具有5个可能值(1111a,2222b,3333c,4444d,5555e)的列的表格,我想将这些结果重命名为我的查询的一部分以下内容:

1111a应重命名为红色 2222b应重命名为蓝色 你得到图片。

我可以使用IIF实现这一目标吗?如果是这样,将不胜感激。如果有更好的方法可以做到这一点,请告诉我。

I'm querying a table with a column that has 5 possible values (1111A, 2222B, 3333C, 4444D, 5555E), I would like to rename those results as part of my query so for each of my results, result should be display as follows:

1111A should be renamed to Red
2222B should be renamed to Blue
You get the picture.

Is this something I could achieve using IIF? If so, an example would be greatly appreciated. If there is a better way to do this, please let me know.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文