C
Charless Mohan
I want to when retrieve data or store date in date/time datatype field. How
can i do?
Thanking You
can i do?
Thanking You
I want to when retrieve data or store date in date/time datatype field. How
can i do?
Thanking You
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])
John W. Vinson said:I want to when retrieve data or store date in date/time datatype field. How
can i do?
Thanking You
A Date/Time field is actually a double float number, a count of days and
fractions of a day (times). As such, a date/time ALWAYS contains a time
portion. This may be zero, midnight, and such date/time values can be treated
as "pure dates" if you wish.
To set a Date/Time field to today's date at midnight ("no time portion") use
the Date() function as its default, or as the source of the date. To enter a
specific date, just enter the date without a time portion - #3/15/2008#.
If a table contains dates with time portions already stored, you can
(permanently and irrevokably) erase the time portion and set it to midnight by
updating the field to Datevalue([fieldname]).
To display only the date portion use a Format without a time portion, such as
Short Date or "mm/dd/yyyy".
To search for records with a date/time on a specific day, ignoring any stored
time portion, use a criterion such as
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])
John W. Vinson said:I want to when retrieve data or store date in date/time datatype field. How
can i do?
Thanking You
A Date/Time field is actually a double float number, a count of days and
fractions of a day (times). As such, a date/time ALWAYS contains a time
portion. This may be zero, midnight, and such date/time values can be treated
as "pure dates" if you wish.
To set a Date/Time field to today's date at midnight ("no time portion") use
the Date() function as its default, or as the source of the date. To enter a
specific date, just enter the date without a time portion - #3/15/2008#.
If a table contains dates with time portions already stored, you can
(permanently and irrevokably) erase the time portion and set it to midnight by
updating the field to Datevalue([fieldname]).
To display only the date portion use a Format without a time portion, such as
Short Date or "mm/dd/yyyy".
To search for records with a date/time on a specific day, ignoring any stored
time portion, use a criterion such as
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])
Charless Mohan said:Thank You So much.
I want when retrieve its show date only in sql select query how can?
example: Its my code
dt = dbcon.selectvalue("Select refno as [Ref No],cardno as [Card
No],cardname as [Card
Name],stmtdate:Format([stmtdate],("dd/mm/yyyy")",duedate as [Due
Date],totamtdue as [Total Amount],paidamt as [Paid Amount],bank as
[Bank],branch as [Branch], chqnodate as [ChqNo/Date], status as [Status],
acctype as [Acct Type],dueperiod as [Periodical] from Reminder");// where
duedate between '" + BasicDatePicker1.SelectedDate + "' and '" +
BasicDatePicker2.SelectedDate + "'");
here is i want retrieve with format Please tell
John W. Vinson said:I want to when retrieve data or store date in date/time datatype field.
How
can i do?
Thanking You
A Date/Time field is actually a double float number, a count of days and
fractions of a day (times). As such, a date/time ALWAYS contains a time
portion. This may be zero, midnight, and such date/time values can be
treated
as "pure dates" if you wish.
To set a Date/Time field to today's date at midnight ("no time portion")
use
the Date() function as its default, or as the source of the date. To
enter a
specific date, just enter the date without a time portion - #3/15/2008#.
If a table contains dates with time portions already stored, you can
(permanently and irrevokably) erase the time portion and set it to
midnight by
updating the field to Datevalue([fieldname]).
To display only the date portion use a Format without a time portion,
such as
Short Date or "mm/dd/yyyy".
To search for records with a date/time on a specific day, ignoring any
stored
time portion, use a criterion such as
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])
Charless said:Thanking You.
I want when retrieve by sql select query its show date only.
how can that : select query format for date only retrieve.
John W. Vinson said:A Date/Time field is actually a double float number, a count of days andI want to when retrieve data or store date in date/time datatype field. How
can i do?
Thanking You
fractions of a day (times). As such, a date/time ALWAYS contains a time
portion. This may be zero, midnight, and such date/time values can be treated
as "pure dates" if you wish.
To set a Date/Time field to today's date at midnight ("no time portion") use
the Date() function as its default, or as the source of the date. To enter a
specific date, just enter the date without a time portion - #3/15/2008#.
If a table contains dates with time portions already stored, you can
(permanently and irrevokably) erase the time portion and set it to midnight by
updating the field to Datevalue([fieldname]).
To display only the date portion use a Format without a time portion, such as
Short Date or "mm/dd/yyyy".
To search for records with a date/time on a specific day, ignoring any stored
time portion, use a criterion such as
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])
Douglas J. Steele said:Rather than
stmtdate:Format([stmtdate],("dd/mm/yyyy")"
you need
Format([stmtdate],"dd/mm/yyyy") AS statedate,
(As far as I'm aware, you cannot name the alias the same as the original
field, hence statedate rather than stmtdate)
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
Charless Mohan said:Thank You So much.
I want when retrieve its show date only in sql select query how can?
example: Its my code
dt = dbcon.selectvalue("Select refno as [Ref No],cardno as [Card
No],cardname as [Card
Name],stmtdate:Format([stmtdate],("dd/mm/yyyy")",duedate as [Due
Date],totamtdue as [Total Amount],paidamt as [Paid Amount],bank as
[Bank],branch as [Branch], chqnodate as [ChqNo/Date], status as [Status],
acctype as [Acct Type],dueperiod as [Periodical] from Reminder");// where
duedate between '" + BasicDatePicker1.SelectedDate + "' and '" +
BasicDatePicker2.SelectedDate + "'");
here is i want retrieve with format Please tell
John W. Vinson said:On Fri, 9 Jan 2009 21:56:01 -0800, Charless Mohan
I want to when retrieve data or store date in date/time datatype field.
How
can i do?
Thanking You
A Date/Time field is actually a double float number, a count of days and
fractions of a day (times). As such, a date/time ALWAYS contains a time
portion. This may be zero, midnight, and such date/time values can be
treated
as "pure dates" if you wish.
To set a Date/Time field to today's date at midnight ("no time portion")
use
the Date() function as its default, or as the source of the date. To
enter a
specific date, just enter the date without a time portion - #3/15/2008#.
If a table contains dates with time portions already stored, you can
(permanently and irrevokably) erase the time portion and set it to
midnight by
updating the field to Datevalue([fieldname]).
To display only the date portion use a Format without a time portion,
such as
Short Date or "mm/dd/yyyy".
To search for records with a date/time on a specific day, ignoring any
stored
time portion, use a criterion such as
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])
George said:I've been successful in using aliases which are the same as the underlying
field name by fully qualifying the table and field in the alias statement.
I don't see the table name in the OP's code, so this is a just a dummy,
wher 'tblNameHere represents the table in which the field stmtdate
appears.
stmtdate: Format([tblNameHere].[stmtdate],("dd/mm/yyyy")"
Douglas J. Steele said:Rather than
stmtdate:Format([stmtdate],("dd/mm/yyyy")"
you need
Format([stmtdate],"dd/mm/yyyy") AS statedate,
(As far as I'm aware, you cannot name the alias the same as the original
field, hence statedate rather than stmtdate)
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
Charless Mohan said:Thank You So much.
I want when retrieve its show date only in sql select query how can?
example: Its my code
dt = dbcon.selectvalue("Select refno as [Ref No],cardno as [Card
No],cardname as [Card
Name],stmtdate:Format([stmtdate],("dd/mm/yyyy")",duedate as [Due
Date],totamtdue as [Total Amount],paidamt as [Paid Amount],bank as
[Bank],branch as [Branch], chqnodate as [ChqNo/Date], status as
[Status],
acctype as [Acct Type],dueperiod as [Periodical] from Reminder");//
where
duedate between '" + BasicDatePicker1.SelectedDate + "' and '" +
BasicDatePicker2.SelectedDate + "'");
here is i want retrieve with format Please tell
:
On Fri, 9 Jan 2009 21:56:01 -0800, Charless Mohan
I want to when retrieve data or store date in date/time datatype
field. How
can i do?
Thanking You
A Date/Time field is actually a double float number, a count of days
and
fractions of a day (times). As such, a date/time ALWAYS contains a time
portion. This may be zero, midnight, and such date/time values can be
treated
as "pure dates" if you wish.
To set a Date/Time field to today's date at midnight ("no time
portion") use
the Date() function as its default, or as the source of the date. To
enter a
specific date, just enter the date without a time portion -
#3/15/2008#.
If a table contains dates with time portions already stored, you can
(permanently and irrevokably) erase the time portion and set it to
midnight by
updating the field to Datevalue([fieldname]).
To display only the date portion use a Format without a time portion,
such as
Short Date or "mm/dd/yyyy".
To search for records with a date/time on a specific day, ignoring any
stored
time portion, use a criterion such as
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])
Douglas J. Steele said:Your Format statement is wrong, though: you've got an extraneous opening
parenthesis, plus an extraneous double quote at the end.
stmtdate: Format([tblNameHere].[stmtdate],"dd/mm/yyyy")
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
George said:I've been successful in using aliases which are the same as the
underlying field name by fully qualifying the table and field in the
alias statement. I don't see the table name in the OP's code, so this is
a just a dummy, wher 'tblNameHere represents the table in which the field
stmtdate appears.
stmtdate: Format([tblNameHere].[stmtdate],("dd/mm/yyyy")"
Douglas J. Steele said:Rather than
stmtdate:Format([stmtdate],("dd/mm/yyyy")"
you need
Format([stmtdate],"dd/mm/yyyy") AS statedate,
(As far as I'm aware, you cannot name the alias the same as the original
field, hence statedate rather than stmtdate)
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
message Thank You So much.
I want when retrieve its show date only in sql select query how can?
example: Its my code
dt = dbcon.selectvalue("Select refno as [Ref No],cardno as [Card
No],cardname as [Card
Name],stmtdate:Format([stmtdate],("dd/mm/yyyy")",duedate as [Due
Date],totamtdue as [Total Amount],paidamt as [Paid Amount],bank as
[Bank],branch as [Branch], chqnodate as [ChqNo/Date], status as
[Status],
acctype as [Acct Type],dueperiod as [Periodical] from Reminder");//
where
duedate between '" + BasicDatePicker1.SelectedDate + "' and '" +
BasicDatePicker2.SelectedDate + "'");
here is i want retrieve with format Please tell
:
On Fri, 9 Jan 2009 21:56:01 -0800, Charless Mohan
I want to when retrieve data or store date in date/time datatype
field. How
can i do?
Thanking You
A Date/Time field is actually a double float number, a count of days
and
fractions of a day (times). As such, a date/time ALWAYS contains a
time
portion. This may be zero, midnight, and such date/time values can be
treated
as "pure dates" if you wish.
To set a Date/Time field to today's date at midnight ("no time
portion") use
the Date() function as its default, or as the source of the date. To
enter a
specific date, just enter the date without a time portion -
#3/15/2008#.
If a table contains dates with time portions already stored, you can
(permanently and irrevokably) erase the time portion and set it to
midnight by
updating the field to Datevalue([fieldname]).
To display only the date portion use a Format without a time portion,
such as
Short Date or "mm/dd/yyyy".
To search for records with a date/time on a specific day, ignoring any
stored
time portion, use a criterion such as
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])
Douglas J. Steele said:Your Format statement is wrong, though: you've got an extraneous opening
parenthesis, plus an extraneous double quote at the end.
stmtdate: Format([tblNameHere].[stmtdate],"dd/mm/yyyy")
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
George said:I've been successful in using aliases which are the same as the
underlying field name by fully qualifying the table and field in the
alias statement. I don't see the table name in the OP's code, so this is
a just a dummy, wher 'tblNameHere represents the table in which the field
stmtdate appears.
stmtdate: Format([tblNameHere].[stmtdate],("dd/mm/yyyy")"
Douglas J. Steele said:Rather than
stmtdate:Format([stmtdate],("dd/mm/yyyy")"
you need
Format([stmtdate],"dd/mm/yyyy") AS statedate,
(As far as I'm aware, you cannot name the alias the same as the original
field, hence statedate rather than stmtdate)
--
Doug Steele, Microsoft Access MVP
(no private e-mails, please)
message Thank You So much.
I want when retrieve its show date only in sql select query how can?
example: Its my code
dt = dbcon.selectvalue("Select refno as [Ref No],cardno as [Card
No],cardname as [Card
Name],stmtdate:Format([stmtdate],("dd/mm/yyyy")",duedate as [Due
Date],totamtdue as [Total Amount],paidamt as [Paid Amount],bank as
[Bank],branch as [Branch], chqnodate as [ChqNo/Date], status as
[Status],
acctype as [Acct Type],dueperiod as [Periodical] from Reminder");//
where
duedate between '" + BasicDatePicker1.SelectedDate + "' and '" +
BasicDatePicker2.SelectedDate + "'");
here is i want retrieve with format Please tell
:
On Fri, 9 Jan 2009 21:56:01 -0800, Charless Mohan
I want to when retrieve data or store date in date/time datatype
field. How
can i do?
Thanking You
A Date/Time field is actually a double float number, a count of days
and
fractions of a day (times). As such, a date/time ALWAYS contains a
time
portion. This may be zero, midnight, and such date/time values can be
treated
as "pure dates" if you wish.
To set a Date/Time field to today's date at midnight ("no time
portion") use
the Date() function as its default, or as the source of the date. To
enter a
specific date, just enter the date without a time portion -
#3/15/2008#.
If a table contains dates with time portions already stored, you can
(permanently and irrevokably) erase the time portion and set it to
midnight by
updating the field to Datevalue([fieldname]).
To display only the date portion use a Format without a time portion,
such as
Short Date or "mm/dd/yyyy".
To search for records with a date/time on a specific day, ignoring any
stored
time portion, use a criterion such as
= [Enter date:] AND < DateAdd("d", 1, [Enter date:])