473,651 Members | 2,566 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Substitute Of Last() Of Ms Acces 2000 in Sql Server 2000

1 New Member
Hi

Does Anybody help me
Substitute Of Last() Function Of Ms Acces 2000 in Sql Server 2000 .

This is my query
-----------------------------------------------------------------------------------------
Select * from AG_IN_OUT_Local where CARDID='" & StrNo & "' and mdate between '" & DateValue(Date) & "' and '" & DateValue(DateA dd("h", -1, MDate)) & "' AND MOut=(Select Last(MOut) From AG_IN_OUT_Local where CARDID='" & StrNo & "' and mdate between '" & DateValue(Date) & "' and '" & DateValue(DateA dd("h", -1, MDate)) & "')")
=============== =============== =============== ===========
this is writtin in Visual basic as frontend here <date> is todays date and
MDate : is date of in
MOut : time
=============== =============== ===========
plz do me help
Jul 22 '07 #1
3 1865
voroojak
92 New Member
i am not sure but i think u can use max() instear of last().
Jul 23 '07 #2
achhabra
1 New Member
The same problem I m facing, have u got any solution of the same, if yes thn plz let knw the same,


Hi

Does Anybody help me
Substitute Of Last() Function Of Ms Acces 2000 in Sql Server 2000 .

This is my query
-----------------------------------------------------------------------------------------
Select * from AG_IN_OUT_Local where CARDID='" & StrNo & "' and mdate between '" & DateValue(Date) & "' and '" & DateValue(DateA dd("h", -1, MDate)) & "' AND MOut=(Select Last(MOut) From AG_IN_OUT_Local where CARDID='" & StrNo & "' and mdate between '" & DateValue(Date) & "' and '" & DateValue(DateA dd("h", -1, MDate)) & "')")
=============== =============== =============== ===========
this is writtin in Visual basic as frontend here <date> is todays date and
MDate : is date of in
MOut : time
=============== =============== ===========
plz do me help
Mar 10 '08 #3
ck9663
2,878 Recognized Expert Specialist
Hi

Does Anybody help me
Substitute Of Last() Function Of Ms Acces 2000 in Sql Server 2000 .

This is my query
-----------------------------------------------------------------------------------------
Select * from AG_IN_OUT_Local where CARDID='" & StrNo & "' and mdate between '" & DateValue(Date) & "' and '" & DateValue(DateA dd("h", -1, MDate)) & "' AND MOut=(Select Last(MOut) From AG_IN_OUT_Local where CARDID='" & StrNo & "' and mdate between '" & DateValue(Date) & "' and '" & DateValue(DateA dd("h", -1, MDate)) & "')")
=============== =============== =============== ===========
this is writtin in Visual basic as frontend here <date> is todays date and
MDate : is date of in
MOut : time
=============== =============== ===========
plz do me help
Is it the same as MAX or MIN ?

-- CK
Mar 10 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

7
1394
by: Wayne... | last post by:
on my hosting acount I have 3 folders that were set up by default: DB LOGS WWW now I understand what each if for obviously, but can i reference back to the databases location outside the www folder from a file using ..../DB/database_name.mdb ? {asssuming of course the file I am referenceing from is in the main WWW folder) I just want to make surfe I get this bit right and stop any weeping wailing and gnashing of teeth lol
4
2762
by: Kona | last post by:
Hello, I would like to known if it is possible to limit acces to a UDB database on Solaris system through db2connect to only specified clients ? My client is a db2connect on Windows platform. Thank you
1
1418
by: Marc | last post by:
Hello, I want to know how I can save data from a MySQL server in Ms Acces format. My situation: pc1: a MySQL server running; pc2: Access running + ODBC MySQL drivers. I can see the data from the MySQL server in Access. This is a link -
2
16529
by: Jeff Marcum | last post by:
I need to write a query in Access that returns the results of a text field with the spaces replaced with underscores. So, if the data in the field was 'hello world', the query results would show 'hello_world'. The SUBSTITUTE function in excel does this. I can't find an equivalent function in Access. In case this helps the syntax in Excel is SUBSTITUTE(text,old_text,new_text,instance_num) Text is the text or the reference to a cell...
5
2885
by: Steve Richter | last post by:
I have a public variable ( "mZipServiceUrl" ) in my code behind class that I am able to substitute into the HTML of the .aspx file: <span onclick="WindowOpen('<%=mZipServiceUrl%>')" style="text-decoration:underline;cursor:hand;color:red;"> <%=mZipServiceUrl%> </span> but in the same page, I cant substitute the same variable into a user control:
4
1186
by: Kevin R | last post by:
Hi All. I am currently studying for MCAD C# and the organization I am studying with have assigned me some online courses to work through as part of my studies. However, one of the courses I have been assigned has not been updated since September 29, 2001. Does anyone think this course is likely to be so out of date now that it might not actually be relevant anymore ? This is the overview of the course:
2
1969
by: malice | last post by:
I have been searching the internet for 12+ hours on how to do this. At this point I'm about to give up. I am using VB .Net 2.0 with the enterprise library jan 2006 release. This is my first time using it and I'm a novice to .Net. I am using the data access quickstart solution and I just started adding my own forms and stuff to it. I got my sql query to work and populate a dataview on my new form with just a few lines of code. Here is my problem...
2
3515
by: Alex | last post by:
Hello all, I'm at a loss on how to do this. We're using MS SQL 2000 Server and I have a list of fields I need to find the first and last entry for. Here's an example of the table: Number - VarChar(10) Jan - Int Feb - Int Mar - Int
1
6567
by: mcasaurabhsumit | last post by:
Hi friend, I am unable to get last record in sql server 2000. How to find last record in sql server 2000?
0
8352
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8275
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8697
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8465
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7297
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5612
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4144
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4283
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1587
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.