Thursday, March 29, 2012
Describe command.
I have some (OLD) college notes that say if I type
Describe tablename;
Name NOT NULL? Type
in my SQL code window in access once run it will give me the structure of the table.
When I try to run I get a Invalid SQL statement error 'DELETE', 'INSERT'...
Where am I going wrong.
Thanksoh, it's simple, your old notes are wrong, access doesn't support that commandsql
Desapering rows
I have an mdx query which return some rows and for some values there are null values for 1 column (it's ok). But when the report is rendered have disapeared all these rows. I need to show these rows because they have value for other columns.
Thanks in advance.I refresh the datasource by editing the query and refresh and that's all.
I don't know what happend.
Tuesday, March 27, 2012
Derived Column Transformation Editor Question
Help...
I'm having trouble coming up with a valid expression in my derived column transformation editor that tests the input column for NULL and responds something like this:
if[message] isNull then "NA" else [message]
where [message] is the input column.
Thanks!
Try:
ISNULL([message]) ? "NA" : [message]
|||SWEET!! Thanks!
Derived Column Transformation Editor Question
Help...
I'm having trouble coming up with a valid expression in my derived column transformation editor that tests the input column for NULL and responds something like this:
if[message] isNull then "NA" else [message]
where [message] is the input column.
Thanks!
Try:
ISNULL([message]) ? "NA" : [message]
Sunday, March 25, 2012
Derived Column Comparison
I am importing States into a table and need to change all NULL fields before I perform a lookup. I'm using a derived column to replace the state value. I'd like to find all States that are blank and set it to "--".
Ironically, this works:
State != "" ? State : "--"
but
State == "" ? State : "--"
Does not work
Can someone tell me why?
Just a guess: the State column really has NULL values (vs. empty strings), which never compare equal to anything. But to explain why the first approach works, there must be some kind of implicit conversion going on.
I think the right way to express what you mean is:
isnull(State) ? "--" : State
|||Or State is a " " (space), not "". Check for both-
ISNULL(State) ? "-" : TRIM(State) == "" ? "-" : State
|||Thanks, the state was not really null, but empty string