I have a trade table with several million rows. Each row represents the version of a trade. If I'm given a possibly new trade I compare it to the latest version in the trade table. If it has changed I add a new version, otherwise I do nothing. In order to compare the 2 trades I read the version from the trade table into my application.
...
Given two floating-point numbers, I'm looking for an efficient way to check if they have the same sign, given that if any of the two values is zero (+0.0 or -0.0), they should be considered to have the same sign.
For instance,
SameSign(1.0, 2.0) should return true
SameSign(-1.0, -2.0) should return true
SameSign(-1.0, 2.0) should ret...
What are the pro's and con's of using "Linq to SQL" and core ADO.NET technology for access databases?
...
Hello guys
I would like to know how to compare two two-dimension arrays value.
First array
Array 1
(
[0] => Array
(
[0] => a
)
[1] => Array
(
[0] => b
)
[2] => Array
(
[0] => c
)
}
Second one
Array 2
(
[0] => Array
...
How can I take two NSArrays, compare them, then return the number of differences, preferably the number of different objects, for example:
Array 1:
one
two
three
Array 2:
two
four
one
I would like that to return "1"
...
Hi, I have a simple question regarding xcode coding but don't know why things are not performing as I think. I have an array of objects (custom objects). I just want to check if this one is within the array. I used the following code:
NSArray *collection = [[NSArray alloc] initWithObjects:A, B, C, nil]; //A, B, C are custom "Item" ob...
In MySQL 4.0.21-standard, I have a table with a date, saved as a string.
I want to compare this string with a date in my request.
SELECT FE_CLIENT.*
FROM FE_CLIENT
WHERE D_DATFINPUBLI < '2010/06/03'
How can I cast my column date_deb to a date for compare?
...
Our application's DB (SQL Server 2005) has tables for application's metadata. Changes to these metadata tables (I mean insert/update/delete) can be done via GUI interface (not using SSMS).
Most of the time developers change their own copy of database. The question is - how to "merge" these changes to metadata records into one? The probl...
Anyone here with experience of the language D?
I was just reading through its presentation at http://www.d-programming-language.org/ and at Wikipedia and it seems like a good (better) alternative to C++.
With good/better I mean that it seem simpler yet it has all the good stuff within C/C++. But without some of the difficulties that m...
Hello.
I'm developing an iPhone application.
I use a NSDictionary to store city's names as key, and population as value. I want to search the keys using lowercase.
I've using this:
NSDictionary *dict;
[dict objectForKey:[[city stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]] lowercaseString]];
But...
I have copy of Grigsoft's Compare it! tool, can anyone tell me how to use it with
Perforce source control?
...
Hi I would like to know diff between the above comparisons?
I am getting null pointer exception when I check object.getItems() == null.
But if I change it to null == object.getItems(), it workes fine.
I did look into this http://stackoverflow.com/questions/2938476/what-is-the-difference-between-null-object-and-objectnull-closed
But I d...
Hello,
i have two String fields who represent Date in my page and i would to compare this two fields to know if my first date < second date
<tr>
<td align="right">First Date: </td>
<td align="left"> <html:text name="addPublicationForm" styleId="firstDate" property="firstDate" maxlength="10"/></td>
</tr>
<tr>
<td align="right">Second Dat...
Hello. I have a file of IP addresses called "IPs". When I parse a new IP from my logs, I'd like to see if the new IP is already in file IPs, before I add it. I know how to add the new IP to the file, but I'm having trouble seeing if the new IP is already in the file.
!/usr/bin/python
from IPy import IP
IP = IP('192.168.1.2')
#f=open(IP(...
Is it a viable option to compare two FileInfo.CreationTimeUtc.Ticks of two files on two different computers to see which version is newer - or is there a better way?
Do Ticks depend on OS time or are they really physical ticks from some fixed date in the past?
...
What you can't do in C (C99 standard) that you can do in Objective-C? (with code example if you please)
...
Hello,
I have problems comparing the datetime property of objects and when trying to
compare to a given date. For example, I tried
IQuery query1 = session.CreateQuery(String.Format(
@"Select s.Id
From InventoryProductStateItem s
Where s.ValidFrom = " + stateItem.ValidFrom));
but get an exception...
I want to create a plugin that displays additional information about Eclipse's compare results. For example, clicking a difference in Eclipse will bring up additional meta-information in my new view about who made the change, when it was made, what are the related changes, etc. I've got everything else figured out except how to call the ...
how do you compare two excel sheet and determine which column is missing?
(would like to compare a list of countries from sheet A with sheet B, then mark which country is missing)
Note: they are in random order.
...
How can I compare two NSDates and return the amount of time between them.
For example:
2010-06-20 14:29:41 -0400
2010-06-20 14:53:29 -0400
should return something like: 23 or 24(minutes), rounding the seconds because I don't really need the seconds.
...