How can I get the previous version of data of a Row in a DataTable? The data has only changed but hasn't been saved yet.
The .NET version I'm working on is 1.1
How can I plot (a 3D plot) a matrix in Gnuplot having such data structure. I cannot find a way to use the first row and column as a x and y ticks (or to ignore them)
,5,6,7,8
1,-6.20,-6.35,-6.59,-6.02
2,-6.39,-6.52,-6.31,-6.00
3,-6.36,-6.48,-6.15,-5.90
4,-5.79,-5.91,-5.87,-5.46
Is the splot 'data.csv' matrix the correct parameter to use ?
Hi
In my app I use a ListView to display data from the database. The data changes sometimes, for example when the user applies new filters or changes the sorting method. I use AsyncTask to get the databsase cursor that points to the new data set because sometimes data needs to be loaded from the net which can take some time.
What I do now looks something like this:
private class updateTask extends AsyncTask<Void, Void, Void> {
/*
* runs on the UI thread before doInBackground
*/
@Override
protected void onPreExecute(){
// prepare some stuff...
}
/*
* runs in a separate thread
* used for time-consuming loading operation
*/
@Override
protected Void doInBackground() {
//get new database cursor
mCursor = mDbAdapter.getCursor();
return null;
}
/*
* runs on the UI thread after doInBackground
*/
@Override
protected void onPostExecute(Void result){
if(mCursor!=null){
MyActivity.this.startManagingCursor(mCursor);
mCursorAdapter = new MyCustomCursorAdapter(MyActivity.this, mCursor);
mListView.setAdapter(mCursorAdapter);
}
}
}
This works so far but I realize that creating a new CursorAdapter and calling setAdapter on my ListView each time isn't the correct way to do it.
Also, after setAdapter the scroll position of the list is set back to the top. I found this post which describes how to do it properly. So now I want to do something like this:
onCreate(){
// ...
// create the CursorAdapter using null as the initial cursor
MyCustomCursorAdapter cursorAdapter = new MyCustomCursorAdapter(this, null);
mListView.setAdapter(cursorAdapter);
// ...
}
private class updateTask extends AsyncTask<Void, Void, Void> {
/*
* runs on the UI thread before doInBackground
*/
@Override
protected void onPreExecute(){
// prepare some stuff...
}
/*
* runs in a separate thread
* used for time-consuming loading operation
*/
@Override
protected Void doInBackground() {
//get new database cursor
mCursor = mDbAdapter.getCursor();
return null;
}
/*
* runs on the UI thread after doInBackground
*/
@Override
protected void onPostExecute(Void result){
// this returns null!
MyCustomCursorAdapter cursorAdapter = (MyCustomCursorAdapter)mListView.getAdapter();
Cursor oldCursor = cursorAdapter.getCursor();
if(oldCursor!=null){
MyActivity.this.stopManagingCursor(oldCursor);
oldCursor.close();
}
if(mCursor!=null){
MyActivity.this.startManagingCursor(mCursor);
cursorAdapter.changeCursor(mCursor);
}
}
}
This however doesn't work for me because
(MyCustomCursorAdapter)mListView.getAdapter();
always returns null.
Why does this happen? What am I doing wrong?
Edit:
Some additional information: my adapter implements SectionIndexer. I don't really think that this has anything to do with my problem but it has caused me some troubles before so I thought I'd mention it.
Hi
I am displaying all the users in the form using php where the data are fetched from db.
When i click on the icon all users data should be show in a pdf with a good table structure.
i am hereby using fpdf to generate it. i created pdf but the records are not in formatted structure.
How should this can be done.
kindly advice.
thanks in advance
strong text
I'm building an iPhone app which needs a peice of meta data from a user's Google Spreadsheet. Unfortunately the meta data I need is not exposed by the API, so I will need to scrape it from the document's HTML source (it would not be present in any of the exported variants).
Is there anyway to include authentication parameters in a call such as:
http://spreadsheets.google.com/ccc?key=abc123&username=...&password=...
I have event data displaying on a map and I am currently using the geo microformat alongside it however it's not particularly rich to have just a list of locations without any details of what they correspond to.
I've been looking at combining microformats to achieve this and looking for some thoughts on the subject
here is the data i am marking up:
event title, event location [latlong], event address, contact phone, link to full details
My initial thoughts are to use an hCard along with geo? Is there anything better?
Thanks in advance
Has anyone written a YQL open data table for accessing Wikipedia? I've had a hunt around the internet and found mention of people using YQL for extracting various bits of information from Wikipedia pages such as microformats, links or content but I haven't been able to find an open data table that ties it all together.
I am trying to use jQuery AJAX. What my requirement is, i wish to load user names from DB in dataset, convert it to JSON format and store it in memory or using jQuery data for use while a user is browsing my site, i.e for a session. This way I can use autocomplete or my own code to display data to user.
Can anyone help me design such a scenario?
I have an application that I want to represent a users session (just small pieces of data here and there) within a GUID. Its a 16 HEX characters (so 16^16 possible values) string and I want to 'encode' some data within that GUID.
How can I achieve this? I am really after any ideas and implementations here, Ive not yet decided on the best mechanism for it yet.
I would also like encryption to be involved if possible...
Thanks a lot
Mark
I followed the guide here, but for some reason, the table view does not load the data. I know the array exists and there's data in it, but it won't display in the table itself.
I've read similar questions here but I'm still a little confused.
MyCollection extends ArrayList<MyClass>
MyClass implements Data
yet this gives me the "cannot convert from ArrayList to MyCollection"
MyCollection mycollection = somehandler.getCollection();
where getCollection looks like this
public ArrayList<Data> getCollection()
So my assumptions are obviously wrong. How can I make this work like I would like it to
I'm trying to export data to a csv file. It should contain a header (from datastack) and restacked arrays with my data (from datastack). One line in datastack has the same length as dataset. The code below works but it removes parts of the first line from datastack. Any ideas why that could be?
s = ','.join(itertools.chain(dataset)) + '\n'
newfile = 'export.csv'
f = open(newfile,'w')
f.write(s)
numpy.savetxt(newfile, (numpy.transpose(datastack)), delimiter=', ')
f.close()
I've read like 10 or so "tutorials", and they all involve the same thing:
Pull a count of the data set
Pull the relevant data set (LIMIT, OFFSET)
IE:
SELECT COUNT(*)
FROM table
WHERE something = ?
SELECT *
FROM table
WHERE something =?
LIMIT ? offset ?`
Two very similar queries, no? There has to be a better way to do this, my dataset is 600,000+ rows and already sluggish (results are determined by over 30 where clauses, and vary from user to user, but are properly indexed of course).
Hi experts,
i have an input data in excel which has 2000 rows and 60 columns. I want to read this data in matlab but i need to to interchange the rows and the column so that the matrix will be 2000 column and 60 rows. How can i do this in matlab, because excel only has 256 column which cannot hols 2000 column.
Thanks
Hey guys, is there a way to load XML Data Cross-Domain with JQuery (= client side)?
$.get('http://otherdomain.com/data.xml', function(xml) { }
The above doesn't work - do I have to rely on JSONP, or is there a way to load XML?
How can display two detail section's data after completion of first detail section in crystal report of vb2005 like
detail of first detailsection
#one row.........................."
#second row........................."
#three row.........................."
detail of second detailsection
#"one row.............."
#"second row..............."
#"data of third row.............."
What is the easiest way of paginating data that is in divs? Some jquery library for it? Basically I would only need 1/x pages shoqing and arrow buttons to go throught all the data.
i am trying to store large data more than 255 characters in a string datatype but it truncates after 255. how can i achive this basically i need to pass this data to database
Are there any ways to determine what the differences in databases are that affect a SSIS package load performance ?
I've got a package which loads and does various bits of processing on ~100k records on my laptop database in about 5 minutes
Try the same package and same data on the test server, which is a reasonable box in both CPU and memory, and it's still running ... about 1 hour so far :-(
Checked the package with a small set of data, and it ran through Ok
Hi,
I am trying to send a date to the server as part of a get transaction, however, looking at the urls (through firebug), it appears that the var sDate is never replaced with its value.
Sorry i'm very new to JS and Jquery, so this is likely a very elementary mistake - i'm guessing it has something to do with the map that i am trying to pass to $.get?
function drawVisualization(sDate, eDate) {
alert(sDate + eDate);
$.get(
"http://localhost:8080/",
"{'start':sDate}",
function(data) { alert(data); },
"html"
);
I want to produce a JSON file, containing some initial parameters and then records of data like this:
{
"measurement" : 15000,
"imi" : 0.5,
"times" : 30,
"recalibrate" : false,
{
"colorlist" : [234, 431, 134]
"speclist" : [0.34, 0.42, 0.45, 0.34, 0.78]
}
{
"colorlist" : [214, 451, 114]
"speclist" : [0.44, 0.32, 0.45, 0.37, 0.53]
}
...
}
How can this be achieved using the Python json module? The data records cannot be added by hand as there are very many.
We have a stored procedure in Oracle that uses global temporary tables. In most of our other stored procedures, first thing we do is delete data from global temporary tables. However, in few of the stored procedures we do not have the delete's.
Are there any other options other than adding the delete statements? Can something be done on the Server side to forcefully delete data from those temporary tables when that SP is ran?