cursor

Problem with MySQL nested cursors

I have the following bunch of code trying to update a field using 2 cursors the one inside the other. I use the first cursor just to get an id value (1st cursor) and then I get a list of other id values based on that id (2nd cursor). The problem is that the result set from the 2nd cursor contains the last id twice! I can't find the bug! ...

WPF: drawing own cursor - nontrivial problem

i need to implement a cursor with some very specific features: it has to be animated because after n seconds it automatically clicks - so the animation is feedback for the user when the click will happen it has to snap to some of our controls it has to work outside of our application the approaches so far: render my WPF-control i...

What is the best way to change the cursor in JQuery

Hi all, I am new to JQuery. I am trying to add some code in my HTML web page to change the cursor, but I am not sure if it is the best way to do it using JQuery alone rather than doing some self-custom declaration in an external CSS. (I don't know if JQuery has got some built-in CSS properties.) Here is the code for my very simple HTM...

SybaseIQ cursor over atemporary table behaves as read-only even if 'for update' was specified

Hi, I'm attempting to update a temporary table using a cursor that was declared 'for update'. The update does not work: [Error Code: 7732, SQL State: 42W30] ASA Error -633: Update operation attempted on a read-only cursor The sybase iq 12.7 docs says that the cursor becomes read-only under some circumstances, like for example if aggreg...

How to draw a highlight around mouse cursor

I'd like to be able to display a quick animated "flash" around the mouse cursor (similar to the effect in some screen-recording applications). What would be a good way to go about this? My current idea is to display a temporary, floating, transparent window window under the mouse position, animate it, then hide it. But I'm wondering if ...

C commandline app : how to programatically move cursor

Hi, I am writing a commandline calculator in C, and it would be very useful if it had the ability to move the cursor each time you close (for example) a parenthesis highlighting the previous one, like in emacs, etc. For example, if you launch emacs, and type: (blah) then for a while after you type the closing parenthesis, the first ...

Using Cursor in a Loop of a stored procedure

So as to use cursors dynamically using MySQL is it possible to declare a cursor in a loop of a stored procedure? I've tried and got an error: increment: LOOP DECLARE cur1 CURSOR FOR SELECT person_id, publication_id FROM p_publication WHERE person_id = new_count; DECLARE CONTINUE HANDLER FOR NOT FOUND SET done = 1; OPEN cur1; REPEAT ...

How can I clear TCanvas? Or any other solution.

I'm using this TCanvas to draw cursors for my mice Canv := TCanvas.Create; Canv.Handle := GetWindowDC(0); .... For every mice event do the following Bitmap:=TBitmap.Create; CursorInfo.cbSize := sizeof(CursorInfo); GetCursorInfo(CursorInfo); Bitmap.Width := 32; Bitmap.Height := 32; Bitmap.Transparent:=true; DrawIconEx(Bitmap.Canvas....

How to change cursor based on mouse position ?

I would like to change the cursor from default to pointer when the mouse enter the rectangle (50, 50, 100, 100) of the body element (the numbers are in pixels). I know that I could define a div, place it at this position, and set cursor: pointer; on it, but I'm looking for some way without defining a div. I would like to something like...

get cursor from array

Is it possible to get an android cursor from an array (either ArrayList or StringaArray)? ...

VB.Net Get name of chrome textbox

Hello, I am trying to fetch the name of the textbox my cursor is currently in or over in a Google chrome browser window. Is this possible? And if so, how would I go about doing it. Thanks! ...

Android: ListView using two cursoradapters?

I have some code which executes two queries against a database and returns two cursor objects. Is there any way that I can combine these two cursors so that all the ListView gets the data from both? ...

Getting the cursor position using javascript not working in firefox

Hello, I have a javascript like function getCursorPosition(e) { e = e || window.event; var cursor = {x:0, y:0}; if (e.pageX || e.pageY) { cursor.x = e.pageX; cursor.y = e.pageY; } else { cursor.x = e.clientX + (document.documentElement.scrollL...

Is there a way to bulk insert into two tables with FK from one to the other?

I'll give a pseudocode example of my current method and if anyone knows of a method that doesn't work one row at a time, I'd be quite appreciative. I'm using MS SQLServer 2008 define cursor for the data to be inserted (about 3 million records) loop ( insert record into table 1 use scope_identity() to get key insert record into tab...

iBatis error when applying parameter map - Caused by SQLException: Cursor is closed

I am debugging an issue with a null ResultsMap returned from calling a stored procedure via iBatis for java. Here is a truncated copy of the exception I'm receiving. DataAccessException: Exception calling procedure Caused by: com.ibatis.common.jdbc.exception.NestedSQLException: --- The error occurred in ibatis-map.xml. --- The error ...

An IF statement in a cursor adapter??

private void datafill() { Cursor notesCursor = mDbHelper.fetchAllNotes(); startManagingCursor(notesCursor); /* JournalRowId is the row id from the first database containing all journal names All notes are kept in database 2. I want only the notes that correspond to each journal to be listed, KEY_...

Oracle read nth column using a cursor

hi, can i read column data in a cursor giving the index of the column? thanks... From the questioner's comments : "I need to create a generic procedure which will read a table or view (name of the view or table is the argument of the proc) and encrypt the data in the column and then will write the encrypted data to a OS file. " ...

Android: Extended CursorAdapter issues

I've got some code which queries a rest api on a service which then updates a database, I then have a cursor which looks at the database. I got some of the underlaying framework from the google iosched app. Calls to mRunnersAdapter.notifyDataSetChanged() in the onReceiveResult method don't seem to do anything, it's only by manually i...

Best way to join tables using sqlite in android.

I am trying to find out the best way to do a simple table join on my two tables using a sqlite database in an android application. Is the simplest way to use CursorJoiner or is there any easier way? ...

ListActivity with Cursor

Does anyone know of a simple example that uses the CursorAdapter? Here's what I'm doing now and it's crashing with a RuntimeException. I'm sure it something simple I'm missing given that I'm a newbie and can't find any simple examples of a ListView that uses a Cursor. Thanks, ... public final class MyListActivity extends ListAct...