473,404 Members | 2,178 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

select command using oledb data base

i have multiple data in my data base. Im using C# form And i created 2 buttons that have the function of previous and next. I dont know what will do to make this 2 buttons funtionable.
Oct 3 '07 #1
1 1662
nico5038
3,080 Expert 2GB
Hmm, I'm no C# expert, but it looks to me you'll need to issue queries that are collecting the data using a < or > comparison of the keyvalue on the displayed form.
For getting the next records use:
select * from tblX where Key > "<substitute present key>" Order by Key
for previous records:
select * from tblX where Key < "<substitute present key>" Order by Key Desc
The OrderBy will give the first record to be the needed one.

Ofcourse EOF and BOF need to be taken care of.

Nic;o)
Oct 6 '07 #2

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

Similar topics

7
by: iqbal | last post by:
Hi all, We have an application through which we are bulk inserting rows into a view. The definition of the view is such that it selects columns from a table on a remote server. I have added the...
5
by: What-a-Tool | last post by:
What is the proper format for my SQL str using command.execute? Even though I know I have matching data in my table, I keep coming up with a ..RecordCount of -1. What am I doing wrong? Thanks in...
7
by: Dave | last post by:
I'm fairly new to C# and I must be misunderstanding something: I have created a standard web ASP.NET web application project and put data controls into it. Right at the top is a whole set of...
7
by: Brian | last post by:
Hello all - I am trying to Insert a new record to an Access 2002 database. Following the insert, I need to obtain the primary key of the inserted row (person_ID) which is an Autonumber field. I...
5
by: mabond | last post by:
Hi VB.NET 2005 Express edition Microsoft Access 2000 (SP-3) Having trouble writing an "insert into" command for a Microsoft table I'm accessing through oledb. I've tried to follow the same...
13
by: PinkBishop | last post by:
I am using VS 2005 with a formview control trying to insert a record to my access db. The data is submitted to the main table no problem, but I need to carry the catID to the bridge table...
2
by: johnlarson | last post by:
I am trying to populate a datagrid from a select statement that contains variables. I can query the dbf file and get the whole file but when I try a select statement with variables from text box and...
2
by: frank | last post by:
I am looking for a way to select some data from a Access database into my SQL database. In Enterprise manager, I want to do someting like: SELECT InvoiceNo, CID FROM...
1
by: a | last post by:
Dear Frends I have this code but I don't know the SQL Code to copy data from CSV file to new table in the current access data base What is SQl Command needed??? Imports System.Data.OleDb ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
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...
0
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
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,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

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.