update

handle flash application update

Hi We build a Flex/J2EE application deployed in several site. When we update the application, we warn the client, shutdown tomcat, do our stuff, and warn the client client again that he can go back to work. For now, it's fine : BUT, some of the client forget to restart they browser. So the .swf ( the flash part ) of our application rem...

Help with ON DUPLICATE KEY UPDATE implementation/design

I have a table, sessionBasket, that holds a list of the items in the shopping baskets of visitors to my site. It looks like: id INT NOT NULL AUTO_INCREMENT PRIMARY KEY usersessid VARCHAR date_added DATETIME product_id INT qty INT My add to basket script first checks for the presence of an item with the current product_id in this table ...

Multi-table Update(MySQL)

Hey all, I have a question regarding multi-table update(MySQL). Consider table t1 and t2. The PKEY for t1 is 'tid' which is a foreign Key in t2. There is a field "qtyt2" in t2 which depends on a field called "qtyt1" in table t1. Consider the foll SQL statement: UPDATE t2,t1 SET t2.qtyt2=IF(( t2.qtyt2- t1.qtyt1 )<0,0,( t2.qtyt2- ...

how to update iphone Simulator and Device to 3.1?

Hi, I have Xcode version 3.1.3 and in that Simulator and Device is supported till 3.0. I want to update the Simulator and Device for 3.1.After that i will be able to put my data from Xcode to My Real Device OS 3.1. how to update from 3.0 to 3.1 in Xcode in Mac mini? If any body has any resolution or any other way ,which would apprecia...

asp.net detailsview update method not getting new values

Hi all, I am binding a detailsview with objectdatasource which gets the select parameter from the querystring. The detailsview shows the desired record, but when I try to update it, my update method gets the old values for the record (and hence no update). here is my detailsview code: <asp:DetailsView ID="dvUsers" runat="server" Height=...

How can I conditionally update a text/ntext field in SQL?

In a stored procedure I'm trying to conditionally update a field (like the 2nd line in the SQL statement below) UPDATE [some_stuff] SET last_update = CASE WHEN val = @NewVal THEN last_update ELSE GETDATE() END, val = @NewVal ...but for a text/ntext field. What's the most efficient way to go about doing that? Does it have to be a s...

Bidirectional replication update record problem

Hi, I would like to present you my problem related to SQL Server 2005 bidirectional replication. What do I need? My teamleader wants to solve one of our problems using bidirectional replication between two databases, each used by different application. One application creates records in table A, changes should replicate to second datab...

Can I update the result (sys_refcursor) of an Oracle stored procedure (in Java)?

Given the following function: create or replace FUNCTION "GETADDRESSES" RETURN sys_refcursor IS address_cursor sys_refcursor; BEGIN OPEN address_cursor FOR SELECT * FROM Address; RETURN address_cursor; END; I would like to be able to make changes to this result set in Java and post the changes back to the data...

How to use join in an HQL update?

I know how to join tables in an SQL update but how do I do it in HQL? Long story: I have items which I process in a run. Each run as an ID and I have a many-to-many relation between items and runs (which is in an extra table). Now I want to set the state of all items used in a certain run. The naive approach looks like this: update It...

Distributing iPhone Ad Hoc Updates

I am using ad hoc distribution to run a beta test program and have run into a couple issues with distributing app updates. The only way I have been able to get an app update on a device through ad hoc distribution is to delete the app from the device first and then install the update. This adds extra steps for beta testers and erases t...

ASP ADO Connection

i want to make connection of ASP to a database and display the records, add update and delete them all in one coding. Waiting for your kind response. ...

RPM technique for handling cumulative updates?

RPM seems to be pretty good at checking dependencies and handling individual file updates, but what is the best practice for handling cumulative updates to, say, a relational database across multiple versions? For instance, say you have product Foo with versions 1.2.1, 1.2.2, 1.2.3, and 1.3.0. In each of these, there were database sche...

VB.NET Dataset update

I'm new to vb.net and having quite a challenge with updating a field in a table using the For...Next construct on a data set. Sample code below - can anyone tell me what I'm missing? I know this particular example could be accomplished with a simple SQL update statement, but the actual use for what this code will become requires steppi...

Creating batch updates from within Java

I want to update every row on a specific column in a mySql database. Currently I am using a java.sql.PreparedStatement for each row and iterating in a for loop. I was wondering if there were any other alternatives in terms of Java programming to make this less time and resource consuming (something like executing the prepared statements ...

MySql "INSERT … ON DUPLICATE KEY UPDATE" still inserting duplicate records. What am I missing?

I have a simple table set up with two columns, each column is a key value. the values stored in each field are varchar(45) representing an email address and a keyword. It is possible that the information collected may duplicate itself as it is related to site browsing data collection. To avoid duplicate entries, I used tried to use INSER...

PostgreSQL 8.2: require specific column to be present in UPDATE statement

I would like to force user to specify origin of update to some table (sometbl), eg. to specify 'local' or 'remote' (for col2) - but checking of that requirement should occur at DB level when UPDATE statement is executed so: UPDATE sometbl SET col1 = 'abc'; should throw error (exception), but: UPDATE sometbl SET col1 = 'abc', col2 = '...

update Android ListActivity when list data changes

i want to know how to refresh the ListActivity when i change/add data to the list wich is dispayed. i first thougt the ListAdapter would know when the list is changed but when i add elements to the list there is no update, only when i close the activity and reopen it i see the changes. so i searched for any update() refesh() or somethin...

getting an error while upgrading my application in android market

Whenever I try to upgrade my application in android market I am getting this error: "The apk must be signed with at least one certificate in common with the previous version" and I have lost my previous keystore. Any help will be appreciated ...

T-SQL conditional UPDATE

If I have an update statement like this: UPDATE Message SET Subject = Subject ...will SQL Server actually perform an update or is it smart enough to recognize that no update is really needed? ...

T-SQL conditional UPDATE (v2)

Hi, I have a table: Message (MessageID int, Subject nvarchar(100), Body nvarchar(max)) After a message is being updated on UI, I call a stored proc to update that table. In some cases user might update just subject, in other cases just body. I want this stored proc to only update what has changed, so I'm also passing flags showing wh...