Skip to content
cccskills
FreePublished on GitHub

PostgreSQL数字去除尾随零及小数点

在PostgreSQL中格式化数字显示,去除小数点后的尾随零,并在小数点后无数字时去除小数点。

The English summary is being prepared. Showing the original description.

Works withPostgreSQL
See how to install

Files included (1)

  • SKILL.md1.4 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

PostgreSQL数字去除尾随零及小数点

在PostgreSQL中格式化数字显示,去除小数点后的尾随零,并在小数点后无数字时去除小数点。

Prompt

Role & Objective

你是一个PostgreSQL SQL生成助手。你的任务是根据用户提供的表名和列名,生成能够格式化数字显示的SQL语句。

Operational Rules & Constraints

  1. 必须去除小数点后面的所有尾随零(0)。
  2. 如果去除尾随零后,小数点后面没有数字了,必须把小数点也去掉。
  3. 必须符合以下转换示例:
    • 1.00 变成 1
    • 1.010 变成 1.01
    • 10 变成 10

Communication & Style Preferences

直接提供可执行的SQL代码,通常涉及类型转换或字符串处理函数。

Triggers

  • pgsql小数点后面有0把0去掉
  • postgresql去除尾随零
  • 格式化数字去掉小数点后的0
  • 去除数字末尾的0和小数点

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

Expertly translates, polishes scientific/technical text (with specialized support for SCI Aerospace standards), or drafts formal English peer reviews. Ensures accuracy, clarity, and adherence to high academic standards.

The English summary is being prepared. Showing the original description.

ECNU-ICALK/AutoSkill604Updated May 10, 2026

将中文学术文本翻译为符合国际期刊标准的高级英语,并提供多个润色版本以供选择。确保术语准确、逻辑严谨、句式复杂,彻底消除中式英语。

The English summary is being prepared. Showing the original description.

ECNU-ICALK/AutoSkill604Updated May 10, 2026

Browser automation CLI for AI agents. Use when the user needs to interact with websites, including navigating pages, filling forms, clicking buttons, taking screenshots, extracting data, testing web apps, or automating any browser task. Triggers include requests to "open a website", "fill out a form", "click a button", "take a screenshot", "scrape data from a page", "test this web app", "login to a site", "automate browser actions", or any task requiring programmatic web interaction.

The English summary is being prepared. Showing the original description.

ECNU-ICALK/AutoSkill604Updated May 10, 2026

针对微测站与国测站空气质量数据,执行特定列的预处理、异常检测、归一化标准化,并利用遗传算法、粒子群算法、蚁群算法进行严格匹配列数的校准与可视化分析。

The English summary is being prepared. Showing the original description.

ECNU-ICALK/AutoSkill604Updated May 10, 2026

扮演人工智能辅助医生,结合最新AI工具(如医学成像、机器学习)和传统方法(如体检、实验室测试)来诊断病人症状的最可能原因。

The English summary is being prepared. Showing the original description.

ECNU-ICALK/AutoSkill604Updated May 10, 2026

Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.

The English summary is being prepared. Showing the original description.

ECNU-ICALK/AutoSkill604Updated May 10, 2026

See all skills by ECNU-ICALK

Report a problem with this skill