Hi,
I have an xml file that can contain a lot of records and I am using
dataset.readxml to read in the file. When looking on what I do with those
records, I am interested only the most recent ones (the last few hundreds).
Unfortunately, the readxml loads the whole 10 000s of them. Is there a way
to specify the loading of the last few hundreds only?
Anthony. 2 1465
No. ReadXml doesn't have any overloads like that. Maybe you can find a way
to perform the limit filtering when the file is written.
-- Peter
// Abandon all hope, ye who enter here. http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com
"ATT" wrote:
Hi,
I have an xml file that can contain a lot of records and I am using
dataset.readxml to read in the file. When looking on what I do with those
records, I am interested only the most recent ones (the last few hundreds).
Unfortunately, the readxml loads the whole 10 000s of them. Is there a way
to specify the loading of the last few hundreds only?
Anthony.
"ATT" <AT*@discussion s.microsoft.com wrote in message
news:34******** *************** ***********@mic rosoft.com...
I have an xml file that can contain a lot of records and I am using
dataset.readxml to read in the file. When looking on what I do with those
records, I am interested only the most recent ones (the last few
hundreds).
Unfortunately, the readxml loads the whole 10 000s of them. Is there a
way
to specify the loading of the last few hundreds only?
Instead of using ReadXml, you could use an XmlReader to read the nodes
sequentially, which is a very fast operation. Just ignore the nodes you want
to skip until you arrive at those that interest you. If their structure is
complex, instead of analyzing them with the XmlReader, you can dump their
content into a MemoryStream, and then use ReadXml to load the DataSet from
the MemoryStream. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Jeffrey A. Voigt |
last post by:
I'm having trouble loading some xml data into a dataset via the ReadXML
call. I'm loading into the dataset an xml schema prior to the ReadXML call.
I see that there IS in fact, 3 records that should be created in the dataset
with the provided xml. However, after the ReadXML statement there are no
rows in the DataSet.Tables ? IS there something I'm missing? I can
assure you that the schema is correct, since it was originally created with...
|
by: mr_dom_is |
last post by:
Hi I have a little bit of trouble, probably missing the point now sure
but:
I have a dataset
dim ds as new dataset("User")
Which is populated with data from a database.
When I use
|
by: Nikhilesh Mehendale |
last post by:
I have written a web service in C#, .NET 1.1 which reads a XML file into a
dataset.
This is just a plain XML file. First I use the Dataset.ReadXmlScheme
function and pass the XML file to it. Then I convert data type of one of the
column to integer and then I use the Dataset.ReadXml function and pass the
same file to it. This works on my machine, but when I run it on a .NET 2.0
machine it thows an exception with message "Input string was...
|
by: kids_pro |
last post by:
I had come across a code block from Loading a DataSet from XML (.NET
Framework Developer's Guide)
----------------------------------------
NOte If you call ReadXML to load a very large file, you may encounter slow
performance. To ensure best performance for ReadXml, on a large file, call
the DataTable.BeginLoadData method for each table in the DataSet, then call
ReadXml. Finally, call DataTable.EndLoadData for each table in the DataSet
as...
|
by: mr_dom_is |
last post by:
Hi I have a little bit of trouble, probably missing the point not sure
but:
I have a dataset
dim ds as new dataset("User")
Which is populated with data from a database.
When I use
| |
by: Arne |
last post by:
How do I pass a dataset to a webservices? I need to submit a shoppingcart
from a pocket PC to a webservice.
What is the right datatype?
II have tried dataset as a datatype, but I can't get it to compile.
<WebMethod()> _
Public Function VerifySku(ByVal skus As XmlDataDocument) As DataSet
Test program :
Dim cartSet As DataSet
cartSet = ws.VerifySku(cartSet)
|
by: Marc |
last post by:
I have used XMLDataToString = DataSetForXML.GetXml() to get an XML string
from a dataset. I am looking for a way to create a dataset from this XML
string. I tried DataSetForXML.ReadXml(XMLDataToString) but I received error
messages. Does anyone know how to do this without creating a file (disk
copy) of this XML data? Thanks for your help.
Marc
|
by: MurdockSE |
last post by:
Greetings.
My Situation:
// I have an .xml file that I am reading into a dataset in the
following code -
DataSet ds = new DataSet("MyDataset");
ds.ReadXml(@"c:\data\"+cmyxmlfilename);
|
by: Mac |
last post by:
I'm trying to validate input from an xml source to a dataset in
dotnet2.0. As far as I can see, type errors correctly cause an
exception, but values that are the correct type but do not satisify
xsd:restriction conditions are ingested without a murmur. Is this a bug
or a feature?
Very frustrating.
Evidence:
1) XML data
<?xml version="1.0" encoding="utf-8"?>
|
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...
|
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
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...
|
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
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...
|
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
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...
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
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...
| |