Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
ProfessorFudger
Starting Member
1 Post |
Posted - 2015-04-13 : 06:21:05
|
Good morning, apologies firstly if in the wrong area, I am new and will be using these forums on a regular basis until I can get the hang and learn more about SQL Server. I'm currently using Management Studio 2008 R2 and struggling as I am very raw to SQL full stop eg a complete newbie to it.WHERE (((dbo_ED_ATTENDANCE.AttendDateTime)>=Date()-IIf(Weekday(Date(),2)<2,4,2) And (dbo_ED_ATTENDANCE.AttendDateTime)<=Date()-1)The above criteria is cut from an existing Access query which I am trying to replicate in SQL Management Studio 2008 R2. Is this doable. |
|
Kristen
Test
22859 Posts |
Posted - 2015-04-13 : 06:25:59
|
Yes, doable, but the syntax is significantly different.Not sure that just offering you the correct syntax will help much - you'll only be 5 minutes before you hit the next difference.Might be better than you familiarise yourself with the basics of T-SQL as is used by MS SQL (which is largely the same as ANSI SQL, which is, sadly, not the case for Access - so Access has lots of its own "flavour" of SQL). |
|
|
|
|
|