473,509 Members | 2,763 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Select Using .Net

LIN
Hi,

I have dataset which contains the data like this

TranDate PurchaseVal
------------ -------------
2003-01-01 51
2003-01-02 52
2003-01-03 54
2003-01-04 53
2003-01-05 54
2003-01-06 56
2003-01-07 58
2003-01-08 52
2003-01-09 51
2003-01-10 55

From this data I want weekly Info

Week Value
1 208
2 ---
3 ---

How I can get this

If I am using .Select("DatePart(week,TranDate)= " & 1)
it is giving me the error DatePart is not defines
Need Advice

LIN


Nov 20 '05 #1
3 1319
"LIN" <ju******************@football.com> schrieb
Hi,

I have dataset which contains the data like this

TranDate PurchaseVal
------------ -------------
2003-01-01 51
2003-01-02 52
2003-01-03 54
2003-01-04 53
2003-01-05 54
2003-01-06 56
2003-01-07 58
2003-01-08 52
2003-01-09 51
2003-01-10 55

From this data I want weekly Info

Week Value
1 208
2 ---
3 ---

How I can get this

If I am using .Select("DatePart(week,TranDate)= " & 1)
it is giving me the error DatePart is not defines


This is an ADO.NET related question because the dataset is part of ADO.NET.
Please turn to microsoft.public.dotnet.framework.adonet.
--
Armin

Nov 20 '05 #2
Hello,

"LIN" <ju******************@football.com> schrieb:
I have dataset which contains the data like this


This is a VB.NET language group. Notice that you will have a better
chance to get an answer if you post to the ADO.NET newsgroup in future:

news://msnews.microsoft.com/microsof...amework.adonet

Web interface:

http://msdn.microsoft.com/newsgroups...amework.adonet

--
Herfried K. Wagner
MVP · VB Classic, VB.NET
http://www.mvps.org/dotnet
Nov 20 '05 #3
LIN,
The best list I know of (only list I know of) that identifies what is
supported in Expressions in ADO.NET is:

http://msdn.microsoft.com/library/de...ssionTopic.asp

I do not see DatePart listed, so as the others have stated, you may want to
ask this 'down the hall' in the microsoft.public.dotnet.framework.adonet
newsgroup.

Hope this helps
Jay

"LIN" <ju******************@football.com> wrote in message
news:e0**************@TK2MSFTNGP11.phx.gbl...
Hi,

I have dataset which contains the data like this

TranDate PurchaseVal
------------ -------------
2003-01-01 51
2003-01-02 52
2003-01-03 54
2003-01-04 53
2003-01-05 54
2003-01-06 56
2003-01-07 58
2003-01-08 52
2003-01-09 51
2003-01-10 55

From this data I want weekly Info

Week Value
1 208
2 ---
3 ---

How I can get this

If I am using .Select("DatePart(week,TranDate)= " & 1)
it is giving me the error DatePart is not defines
Need Advice

LIN

Nov 20 '05 #4

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

Similar topics

21
5215
by: John Fabiani | last post by:
Hi, I'm a newbie and I'm attempting to learn howto create a select statement. When I use >>> string1='18 Tadlock Place' >>> cursor.execute("SELECT * FROM mytest where address = %s",string1) All...
3
8090
by: Memduh Durmaz | last post by:
Hi, I'm using DB2 UDB 7.2. Also I'm doing some tests on SQL Server 2000 for some statements to use efectively. I didn't find any solution on Sql Server about WITH ... SELECT structure of DB2. ...
6
2787
by: RCS | last post by:
I've been running into more and more complexity with an application, because as time goes on - we need more and more high-level, rolled-up information. And so I've created views, and views that use...
6
3013
by: Sjaakie | last post by:
Hi there, I'm trying to get this working with Firefox. Can you point out what's wrong? No problems with IE, Firefox doens't fill selMonth... TIA >>> the script... >>> <select name="selDay"...
10
5586
by: serge | last post by:
Using "SELECT * " is a bad practice even when using a VIEW instead of a table? I have some stored procedures that are identical with the difference of one statement in the WHERE clause. If I...
3
6425
by: Tcs | last post by:
My backend is DB2 on our AS/400. While I do HAVE DB2 PE for my PC, I haven't loaded it yet. I'm still using MS Access. And no, I don't believe this is an Access question. (But who knows? I...
6
12965
by: Chris Fink | last post by:
Does anyone know it is possible to include a small image(.gif .jpeg) within a <SELECT><option> so that the user would see the option text as well as a little image(icon) in the option? I know this...
2
1880
by: Pavel Stehule | last post by:
Hello, Pg make query 1. and 2. very fast (use index), but for query 3. dont use index. I can solve its using select union, but I readed so pg 7.5 don't problem with OR operator. I use cvs pg. I...
1
2949
by: Joe Attardi | last post by:
Hi all, On a form on one of my pages I have two <select> elements, and each one is paired up with a radio button. The idea is to choose an item from one list or the other and select the radio...
4
2250
by: Ian Richardson | last post by:
Hi, The function I've put together below is a rough idea to extend a SELECT list, starting from: <body> <form name="bambam"> <select id="fred"> <option value="1">1</option> <option...
0
7135
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
7505
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
5650
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,...
1
5060
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...
0
4729
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...
0
3215
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...
0
3201
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1570
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
774
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.