Search Results

Search found 558 results on 23 pages for 'jeremy smyth'.

Page 14/23 | < Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >

  • How to formulate a SQL Server indexed view that aggregates distinct values?

    - by Jeremy Lew
    I have a schema that includes tables like the following (pseudo schema): TABLE ItemCollection { ItemCollectionId ...etc... } TABLE Item { ItemId, ItemCollectionId, ContributorId } I need to aggregate the number of distinct contributors per ItemCollectionId. This is possible with a query like: SELECT ItemCollectionId, COUNT(DISTINCT ContributorId) FROM Item GROUP BY ItemCollectionId I further want to pre-calculate this aggregation using an indexed (materialized) view. The DISTINCT prevents an index being placed on this view. Is there any way to reformulate this which will not violate SQL Server's indexed view constraints?

    Read the article

  • How to use Zend Cache with SimpleXML objects?

    - by Jeremy Hicks
    I'm trying to cache the user timeline of a Twitter feed using Zend_Service_Twitter which returns its results as a SimpleXML object. Unfortunately the regular serialize functions (which Zend Cache uses) don't play nice with SimpleXMl objects. I found this http://www.mail-archive.com/[email protected]/msg18133.html. So it looks like I'll need to create some kind of custom frontend for Zend Cache to be able to change the serialize function used. Anybody ever done this already or can point me where to look to start?

    Read the article

  • jquery: mouseleave event seems to fire when it's not supposed to

    - by Jeremy
    Given the following html table and script shown below I am having a problem where the mouse leave event appears to fire right after the mouse enter, even if I don't move the mouse out of the row. <script type="text/javascript" language="javascript"> function highlightRows(iMainID) { $('tr[mainid=' + iMainID+ ']').each(function() { if ($(this).attr('old') == undefined) { $(this).attr('old', $(this).css('backgroundColor')); } $(this).animate({ backgroundColor: "#FFFFCC" }, 500); $(this).mouseout(function() { if ($(this).attr('old') != undefined) { $(this).animate({ backgroundColor: $(this).attr('old') }, 500); } }); }); } </script> <table> <tr> <td mainid="1" onmouseover='highlightRows(1)'><div>text</div></td> <td mainid="1" onmouseover='highlightRows(1)'><div>text</div></td> <td mainid="2" onmouseover='highlightRows(2)'><div>text</div></td> </tr> <table>

    Read the article

  • Fast rectangle to rectangle intersection

    - by Jeremy Rudd
    What's a fast way to test if 2 rectangles are intersecting? A search on the internet came up with this one-liner (WOOT!), but I don't understand how to write it in Javascript, it seems to be written in an ancient form of C++. struct { LONG left; LONG top; LONG right; LONG bottom; } RECT; bool IntersectRect(const RECT * r1, const RECT * r2) { return ! ( r2->left > r1->right || r2->right left || r2->top > r1->bottom || r2->bottom top ); }

    Read the article

  • Android: Create TextView that flashes when clicked

    - by Jeremy
    How do I set up a TextView to flash when it is clicked? I essentially want one of the objects that is displayed in a ListActivity, but inside a normal View. I have tried to do this by adding an OnClickListener, but what I really need is something like adding an On(Un)SelectListener. Using the onClickListener, I can change the TextView background, but obviously the background stays that color. I thought of using a new Handler().postDelayed(new Runnable(){ ... }) kind of thing to reset the backround after some small time, but I did not know if this would be overkill for what I'm trying to do. What would you recommend?

    Read the article

  • How do I implement multiple kinds of an object in OOP?

    - by Jeremy Rudd
    I have multiple kinds of an object, say Car for example. Do I have each kind in an inherited class/subclass of Car? Do I place these under a cartype namespace so as not to mess up the main namespace? Then later when I need an array of cars, should I declare it as var currentCars():Car or var currentCars():Object? Would the former support any subclass of Car?

    Read the article

  • Which C# 4.0 Book would you purchase, and why?

    - by Jeremy
    I'm currently looking at purchasing a few C# 4.0 books, namely: Essential C# 4.0 by Mark Michaelis or C# 4.0 Unleashed by Bart De Smet. I am aware that both books are yet to be released, but would you consider purchasing either of these books, or would you recommend another? Thanks for your time. Clarification: I'm not a .net Ninja, but I do have 8+ years experience with the framework & related languages. So I'm generally looking for in-depth books. I also train/instruct the rest of my organisation generally 6 - 12 months after each .net release. Each of the developers I train has the same or more .net experience then myself. Once again thank you all for your time. Update: Thank you everyone for your responses. I've decided to purchase both books along with Visual C# 2010 Recipes: A Problem-Solution Approach, as suggested by Waleed Al Balooshi.

    Read the article

  • Can you define <=> in Ruby and then have ==, >, <, >=, and <= defined automatically?

    - by jeremy Ruten
    Here's part of my Note class: class Note attr_accessor :semitones, :letter, :accidental def initialize(semitones, letter, accidental = :n) @semitones, @letter, @accidental = semitones, letter, accidental end def <=>(other) @semitones <=> other.semitones end def ==(other) @semitones == other.semitones end def >(other) @semitones > other.semitones end def <(other) @semitones < other.semitones end end It seems to me like there should be a module that I could include that could give me my equality and comparison operators based on my <=> method. Is there one? I'm guessing a lot of people run into this kind of problem. How do you usually solve it? (How do you make it DRY?)

    Read the article

  • Mecurial vs Subversion

    - by Jeremy E
    I have a medium sized team of developers who moved to Subversion last December from VSS and I wanted to hear from people who have used both Mecurial and Subversion and get their feedback. What do they really like about Mecurial? What sucks? Is there a better open source tool? I didn't really want to put my devs through the whole source control migration thing again unless it is really worth it. Thanks in advance!

    Read the article

  • Linking individual queries in a unbound listbox in ACCESS 2007

    - by Jeremy
    I have created a unbound listbox. I have the box showing a list of queries I want the use to be able to select. My problem is I don't understand how to get the submit button to select the currently selected query and run it. So how do I link the submit button to the listbox and have each item in the box submit its own query.

    Read the article

  • iOS6 MKMapView using a ton of memory, to the point of crashing the app, anyone else notice this?

    - by Jeremy Fox
    Has anyone else, who's using maps in their iOS 6 apps, noticing extremely high memory use to the point of receiving memory warnings over and over to the point of crashing the app? I've ran the app through instruments and I'm not seeing any leaks and until the map view is created the app consistently runs at around ~3mb Live Bytes. Once the map is created and the tiles are downloaded the Live Bytes jumps up to ~13mb Live Bytes. Then as I move the map around and zoom in and out the Live Bytes continuos to climb until the app crashes at around ~40mb Live Bytes. This is on an iPhone 4 by the way. On an iPod touch it crashes even earlier. I am reusing annotation views properly and nothing is leaking. Is anyone else seeing this same high memory usage with the new iOS 6 maps? Also, does anyone have a solution?

    Read the article

  • Can a storyboard access the UserControl that it resides in?

    - by Jeremy
    I have a usercontrol, and I want a storyboard inside the user control to fade the user control out. Using Expression Blend, I can create the storyboard and cause it to fade the user control out, but when I run the silverlight application I get an error on FindControl stating that it can't find the control. I'm guessing the find control only searches the children of the parent, but does not look at the parent itself. Is there any way around this?

    Read the article

  • WordPress: Display Single Post

    - by Jeremy Person
    I am trying to display a WordPress post on the homepage of a site. It is reporting the following error: Parse error: syntax error, unexpected '=' in /home/####/####/####/####/wp-content/themes/oceanswaves/home.php on line 105 <?php query_posts(‘p=143'); if(have_posts()) : the_post(); ?> <?php the_content(); ?> <?php endif; ?> Thank you

    Read the article

  • Package SWF into an EXE or APP

    - by Jeremy White
    I am trying to adjust my Flash development workflow so that I am using Flash Builder for all of my coding and multiple FLA files for the user interfaces. I will be creating an ActionScript project in Flash Builder and then having each FLA export a SWC into a resources folder. It is important that I retain the ability to export PC and Mac -- EXE and app, respectively -- projector files. Is there a way of doing this with the Flash compiler or any 3rd party tools?

    Read the article

  • How to handle authenticated user access to resources in document oriented system?

    - by Jeremy Raymond
    I'm developing a document oriented application and need to manage user access to the documents. I have a module that handles user authentication, and another module that handles document CRUD operations on the data store. Once a user is authenticated I need to enforce what operations the user can and cannot perform to documents based upon the user's permissions. The best option I could think of to integrate these two pieces together would be to create another module that duplicates the data API but that also takes the authenticated user as a parameter. The module would delegate the authorization check to the auth module and delegate the document operation to the data access module. Something like: -module(auth_data_access). % User is authenticated (logged into the system) % save_doc validates if user is allowed to save the given document and if so % saves it returning ok, else returns {error, permission_denied} save_doc(Doc, User) -> case auth:save_allowed(Doc, User) of ok -> data_access:save_doc(Doc); denied -> {error, permission_denied} end end. Is there a better way I can handle this?

    Read the article

  • clear cookie container in WebRequest

    - by Jeremy
    I'm using the WebRequest object to post data to a login page, then post data to a seperate page on the same site. I am instantiating a CookieContainer and assigning it to the WebRequest object so that the cookies are handled. The problem is that I do not want to retain the cookie after I post data to the other page. How can I delete that cookie?

    Read the article

  • remove schema from linq datacontexts

    - by Jeremy
    When I add stored procedures to a linq datacontext, by default visual studio prefixes the stored procedure with the sql schema that it is in. Is there any way to stop this? In our environment, the stored procedures may be moved to other schemas over time, and we will default the schema based on the sql user used to connect. Do I have to do this manually or can I somehow turn off the schema prefixes?

    Read the article

  • StructureMap: Wiring (generic) implementations to an implementation of another type

    - by Jeremy Frey
    If I have an interface: public interface IRepository<T> And an abstract class: public abstract class LinqToSqlRepository<T, TContext> : IRepository<T> where T : class where TContext : DataContext And a whole bunch of implementations of IRepository / LinqToSqlRepository (e.g. AccountRepository, ContactRepository, etc.), what's the best way to to use StructureMap (2.5.3) to generically wire them all up? e.g., I want this code to pass: [Test] public void ShouldWireUpAccountRepositories { var accountRepo = ObjectFactory.GetInstance<IRepository<Account>>(); Assert.IsInstanceOf<AccountRepository>(accountRepo); } Without explicitly writing this: ObjectFactory.Configure(x => x.ForRequestedType<IRepository<Account>>() .TheDefaultIsConcreteType<AccountRepository>()); In the past, we've always created a specific interface on each repository that inherited from the generic one, and used the default scanner to automatically wire all of those instances, but I'd like to be able to ask specifically for an IRepository<Account> without cluttering up the project with additional interfaces / configurations.

    Read the article

  • Is there a good way of displaying required field indicators when using DataAnnotations in MVC 2?

    - by Jeremy Gruenwald
    I've got validation working with DataAnnotations on all my models, but I'd like to display an indicator for required fields on page load. Since I've got all my validation centralized, I'd rather not hard-code indicators in the View. Calling validation on load would show the validation summary. Has anyone found a good way of letting the model determine what's required, but checking it upon rendering the view, similar to Html.ValidationMessageFor?

    Read the article

  • Parent child class relationship design pattern

    - by Jeremy
    I have a class which has a list of child items. Is there a design pattern I can copy that I can apply to these classes so that I can access the parent instance from the child, and it enforces rules such as not being able to add the child to multiple parents, etc?

    Read the article

  • Can't add domain users to Reporting Services 2008

    - by Jeremy
    I have SSRS 2008 setup on the database server. The server is part of the domain. Reporting Services is running under NetworkService. When I try to add a domain user using the web interface (Site Settings -- Security -- New Role Assignment), the page posts back but the user is not in the list. The server's log file contains the following Unhandled Exception: ui!ReportManager_0-1!954!01/12/2009-10:14:52:: Unhandled exception: System.Security.Principal.IdentityNotMappedException: Some or all identity references could not be translated. at System.Security.Principal.SecurityIdentifier.Translate(IdentityReferenceCollection sourceSids, Type targetType, Boolean forceSuccess) at System.Security.Principal.SecurityIdentifier.Translate(Type targetType) at System.Security.Principal.WindowsIdentity.GetName() at System.Security.Principal.WindowsIdentity.get_Name() at ReportingServicesHttpRuntime.RsWorkerRequest.GetServerVariable(String name) at System.Web.Security.WindowsAuthenticationModule.OnEnter(Object source, EventArgs eventArgs) at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) Any one have an idea on how to fix this?

    Read the article

  • How do I get the IVsTextView of a specific OutputWindowPane?

    - by Jeremy Bell
    I have a visual studio integration package that tracks output from the debug window. I can get the IVsTextView of the output window, like so: IVsTextView view = GetService(typeof(SVsOutputWindow)) as IVsTextView; // grab text from the view and process it However, if a different panel other than the "Debug" panel is currently active, then this IVsTextView will have text from that panel, and not the "Debug" panel. Is it possible to get an IVsTextView for a specific output window panel, without calling OutputWindowPanel.Activate() prior to getting the IVsTextView of the output window?

    Read the article

< Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >