I have tables
tbl_Last_Update
Last_Update (dd:mm:yyyy hh:mm:ss)
tbl_Imported_data
Fields....
Create_stamp (dd:mm:yyyy hh:mm:ss)
I need to create a view showing records from tbl_Imported_data where tbl_Imported_data.Create_stamp > tbl_Last_Update.Last_Update
Problem is how to set criteria into the view.
Expression 'Dmax("[Last_Update]","tbl_Last_Update")' as criteria works fine in MS ACCESS.
Is there any solutions for SQLServer, how to set corresponding expression (referring to other tables or queries) as criteria ?
Thanks in advance
- MarkWhat is the data type you are using datetime/smalldatetime/timestamp ?|||rnealejr:
What is the data type you are using datetime/smalldatetime/timestamp ?
--
Data type is datetime.
Thank a lot for your interest !
BR,
Mark
--|||I am not sure, you may want something like this:
select *
from tbl_Imported_data
where Create_stamp>
(
select max(Last_Update) from tbl_Last_Update
)|||--
I am not sure, you may want something like this:
select *
from tbl_Imported_data
where Create_stamp> (select max(Last_Update) from tbl_Last_Update)
--
This syntax works fine. THANK YOU !
- Mark
Wednesday, March 7, 2012
Expression as criteria
Labels:
create,
create_stamp,
criteria,
database,
ddmmyyyy,
expression,
fields,
hhmmss,
last_update,
microsoft,
mysql,
oracle,
server,
sql,
tablestbl_last_update,
tbl_imported_data,
view
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment