• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2981
  • Last Modified:

SQL to convert to upper case

I need to convert a text in a field called "Bin" to upper case.  I am using Access 20007 front-end and SQL 2005 backend.   Example:
  Table - Inventory, Bin=abc
After convertion:
  Table - Inventory, Bin=ABC
0
schmir1
Asked:
schmir1
3 Solutions
 
chapmandewCommented:
select BIN = upper(bin), otherfields
from yourtablename
0
 
DatabaseMX (Joe Anderson - Microsoft MVP, Access and Data Platform)Commented:
SELECT BIN = UCase(BIN)
FROM YourTableName

mx
0
 
hieloCommented:
Try:
SELECT UCase(BIN) as bin FROM Inventory
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
chapmandewCommented:
If you're doing at the backend level, then you'll need to use UPPER.  If you're doing it at the front-end in Access, then you'll need to use UCASE.
0
 
DatabaseMX (Joe Anderson - Microsoft MVP, Access and Data Platform)Commented:
UPDATE Table1 SET Table1.BIN= UCase([BIN]);

Make a backup first.

mx
0
 
DatabaseMX (Joe Anderson - Microsoft MVP, Access and Data Platform)Commented:
UPDATE Inventory SET Inventory.BIN= UCase([BIN]);
0
 
GRayLCommented:
Update Inventory SET Bin = UCase(Bin);
0
 
schmir1Author Commented:
I used the Update Query because I want the changes saved.  I used the Access version but it is good to know the SQL 2005 version.  Thanks for all your help.
0

Featured Post

[Webinar On Demand] Database Backup and Recovery

Does your company store data on premises, off site, in the cloud, or a combination of these? If you answered “yes”, you need a data backup recovery plan that fits each and every platform. Watch now as as Percona teaches us how to build agile data backup recovery plan.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now