For Duane Hookom... (concatenate fields)...

  • Thread starter Thread starter Kostas Konstantinidis
  • Start date Start date
K

Kostas Konstantinidis

Dear Duane,
As you know I am using your function.
aaa: Concatenate("SELECT Time_ranteboy & ' (' & aitia_pros & ')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "#")
How is possible to return the concatenated field [Time_ranteboy]in 24hours
time format and not
like e.g. 10:30:00am

many thank's
/kostas
 
I'm not Duane, but the answer should be include the format function in the query

Concatenate("SELECT Format(Time_ranteboy,""hh:mm:ss"") & ' (' & aitia_pros &
')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "#")

John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County
 
John,
It works.
Tried to sort the query by date and time but it doesn't work.
It sorts only by date. Should add something else?/
Thank's for all
/kostas

John Spencer said:
I'm not Duane, but the answer should be include the format function in the
query

Concatenate("SELECT Format(Time_ranteboy,""hh:mm:ss"") & ' (' & aitia_pros
& ')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "#")

John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County

Kostas said:
Dear Duane,
As you know I am using your function.
aaa: Concatenate("SELECT Time_ranteboy & ' (' & aitia_pros & ')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "#")
How is possible to return the concatenated field [Time_ranteboy]in
24hours time format and not
like e.g. 10:30:00am

many thank's
/kostas
 
I'm not sure what you meant when you said sort the query by date and time?

If you meant the concatenate function then

Concatenate("SELECT Format(Time_ranteboy,""hh:mm:ss"") & ' (' & aitia_pros &
')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "# ORDER BY Date_RanteBoy,
Time_RanteBoy")

Although you probably only need to sort by Time_RanteBoy since the date is
apparently restricted to one date by the criteria.

If you mean you are trying to sort the overall query of which this is a
calculated column - then I don't see how this would apply from what you have
posted.

John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County

??? ????O? - ??µ?s????af??? ?µ?µa said:
John,
It works.
Tried to sort the query by date and time but it doesn't work.
It sorts only by date. Should add something else?/
Thank's for all
/kostas

John Spencer said:
I'm not Duane, but the answer should be include the format function in the
query

Concatenate("SELECT Format(Time_ranteboy,""hh:mm:ss"") & ' (' & aitia_pros
& ')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "#")
 
That's excatly what I needed
many many thank's John
I wish Mery Christmas and a Happy New Year
to you and your family too

/kostas


John Spencer said:
I'm not sure what you meant when you said sort the query by date and time?

If you meant the concatenate function then

Concatenate("SELECT Format(Time_ranteboy,""hh:mm:ss"") & ' (' & aitia_pros
& ')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "# ORDER BY Date_RanteBoy,
Time_RanteBoy")

Although you probably only need to sort by Time_RanteBoy since the date is
apparently restricted to one date by the criteria.

If you mean you are trying to sort the overall query of which this is a
calculated column - then I don't see how this would apply from what you
have posted.

John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County

??? ????O? - ??µ?s????af??? ?µ?µa said:
John,
It works.
Tried to sort the query by date and time but it doesn't work.
It sorts only by date. Should add something else?/
Thank's for all
/kostas

John Spencer said:
I'm not Duane, but the answer should be include the format function in
the query

Concatenate("SELECT Format(Time_ranteboy,""hh:mm:ss"") & ' (' &
aitia_pros & ')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "#")
 
Thanks John. Have a great Christmas and New Year.

--
Duane Hookom
Microsoft Access MVP


Kostas Konstantinidis said:
That's excatly what I needed
many many thank's John
I wish Mery Christmas and a Happy New Year
to you and your family too

/kostas


John Spencer said:
I'm not sure what you meant when you said sort the query by date and time?

If you meant the concatenate function then

Concatenate("SELECT Format(Time_ranteboy,""hh:mm:ss"") & ' (' & aitia_pros
& ')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "# ORDER BY Date_RanteBoy,
Time_RanteBoy")

Although you probably only need to sort by Time_RanteBoy since the date is
apparently restricted to one date by the criteria.

If you mean you are trying to sort the overall query of which this is a
calculated column - then I don't see how this would apply from what you
have posted.

John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County

??? ????O? - ??µ?s????af??? ?µ?µa said:
John,
It works.
Tried to sort the query by date and time but it doesn't work.
It sorts only by date. Should add something else?/
Thank's for all
/kostas

I'm not Duane, but the answer should be include the format function in
the query

Concatenate("SELECT Format(Time_ranteboy,""hh:mm:ss"") & ' (' &
aitia_pros & ')' FROM
RT_AM_ranteboy
WHERE date_ranteboy =#" & [date_ranteboy] & "#")
 
Back
Top