Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I'm reading from a SQL database, one field are alfanumeric. I want to convert it to text and upper, should I write:
Load Text(Upper(S)) as Title or Load Upper(Text(S)) as Title ?
I think both will work fine, but I would prefer Text(Upper(S)),
Why not try both and see what the results are?
I tried that :
LOAD upper(alpha) as alpha INLINE [
alpha
a34
b
54
];
and I obtain A34,B,54.
Is that what you wanted to do?
Most SQL databases will allow you to convert strings to uppercase within the SQL query. However, not all DBMSs conform to the standard, but most will allow you to use the Upper() function (Mysql, Postgres, Oracle). I think Access uses UCASE(). This allows you to just query select UCASE(S) as QV_field from ...
I have tested both. If I do this:
LOAD upper(text(alpha)) as alpha INLINE [
alpha
01-0003-01
01-0003-1
01-0005-1
123456
];
I obtain 01-0003-01
01-0005-1
123456
If I do this:
LOAD text(upper(alpha)) as alpha INLINE [
alpha
01-0003-01
01-0003-1
01-0005-1
123456
];
I obtain 01-0003-01
01-0003-1
01-0005-1
123456
Why do I get different results?
I am having similar problems. I have 2 SKUs 00056 and 0056. If I use Text(Upper I get 2 unique values. However, if I use Upper(Text I get only ONE value "00056". I believe this to be a bug, but I'm such a newbie that I don't even know where to log it.