ACCESS字符串对话 [英] ACCESS String Converstions

查看:135
本文介绍了ACCESS字符串对话的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,先发帖所以请光临我。还在学习并希望从你们那里学到很多东西。我从来没有在VB上对任何MS软件包进行查询...但查询和我非常了解的事情。


问题...我有一个客户名称的数据库。

例如。

[CUSTOMER_NAME]

CP PRINSLOO


i想要将该字段改为阅读

CP Prinsloo


使用STRCONV([CUSTOMER_NAME],3)...这完全符合我的要求但不幸的是它改变了第二个初始值小客户的顾客!


Cp Prinsloo


如果客户只有一个首字母,它很容易,但我该怎么做保留客户姓名缩写的第二个字符在CAPS中?


请帮忙?

解决方案

砖块。


您可以使用Split()函数获取子字符串数组,然后在一个子字符串(第二个或最后一个?)上执行转换,然后使用Join()函数将它们合并回字符串

FishVal


感谢您的回复,但请原谅我的无知,就像我说的那样......新的并且学习......

去寻找你提到的那些功能什么都没找到?

对它进行了搜索并找不到它......它叫做Split \ Join Function?


Hi Bricks,


这是您正在寻找的查询:

展开 | 选择 | 换行 | 行号


Hi guys, first post so please bare with me. Still learning and hope to learn lots from you guys. I''ve never done queries in VB on any of the MS packages ... but queries and things I know quite well.

Question...i have a database with Customer Names.
eg.
[CUSTOMER_NAME]
CP PRINSLOO

i want to properCase the field to read
CP Prinsloo

by using the STRCONV([CUSTOMER_NAME],3) ... this does exactly what i want but it unfortunately changes the second Initial of the customer to lower case!

Cp Prinsloo

its easy enough if the customer only has one initial, but what can i do to keep the second character of the customer''s initials in CAPS?

please help?

解决方案

Hi, Bricks.

You may use Split() function to get an array of substrings, then perform conversion on one substring (second or last ?) and then merge them back into string using Join() function.


FishVal

thanks for the reply but please forgive my ignorance, like i said...new at this and learning...
went looking for those functions that you mentioned and found nothing ??
did a search on it and could not find it...is it called Split \ Join Function?


Hi Bricks,

This is the Query you are Looking For :

Expand|Select|Wrap|Line Numbers


这篇关于ACCESS字符串对话的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆