473,320 Members | 1,965 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,320 software developers and data experts.

SQL SELECT query on DataSet(not fill)

Hi

I need execute SELECT SQL query in DataSet. No in SQL
server(da.selectcommand) and fill dataset, only show in datagrid
filtered by select-where query records from dataset:) For example I
fill dataset(ds)
da.selectcommand.commandtext="select * from xxx"
da.fill(ds.tables(0))

and when i write
datagrid.datasource=da.tables(0)
datagrid show me all records, but here i need something, i don't know
what, maybe DataView wich allow me to show in datagrid only records
WHERE for example city=London. Is it possible?? maybe RowFilter??

Mrozu

Nov 21 '05 #1
1 7098
Mrozu,

ds.tables(0).DefaultView.rowfilter = "city = 'London'"
datagrid.datasource=ds.tables(0).Defaultview

I hope this helps,

Cor
Nov 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Cyrille \cns\ Szymanski | last post by:
Hello, I have a XML document which is typically : <course> <section> <title>Foo</title> There comes the text </section> <section>
8
by: VM | last post by:
If I want to run this query ( " col_output like '<del> *BOX' " ), it'll throw an exception. How can I search for any rows that begin with '<del>' and end with 'BOX'? Would it also be possible to...
4
by: Kris Rudin | last post by:
I am displaying a table of information on a web page, using an asp:table that I populate dynamically. On this page I give the user the options to group the rows by certain fields, and/or filter the...
4
by: John Rose | last post by:
I have one databound TextBox on a page with one button. The TextBox loads the correct SQL record data but typing a new string into the Textbox fails to change the DataSet. Any ideas? There must...
2
by: VB Programmer | last post by:
I have a dataset which I fill in the Page_Load (only 'If Not Page.IsPostBack'). When I debug the load: dsmyds1.Tables(0).Rows.Count = 207 When I click on a button and it posts back the...
1
by: chreo | last post by:
Hello. Does anybody had problem with VB application with MS SQL Database? I have DATAGRID which shows TABLE from DATABASE. Next I add new ROW to TABLE with SQLcommand (stored procedure) ...
9
by: Udo Marx | last post by:
Greets to ciwah! I'm doing a little webproject for a local session event. Tryin' to meet latest standards i failed to do this: --snip-- <select name="fromcountry" accesskey="l" title="+">...
4
by: tshad | last post by:
I have a program that is reading a .csv file into a dataset and works fine except that it is dropping the first line. I assume that is because it is dropping the header. The problem is the first...
1
by: hazelra | last post by:
Can Access do a "SELECT * NOT IN SELECT..." kind of query? What is the proper syntax?
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.