Search Results

Search found 8953 results on 359 pages for 'human resources'.

Page 195/359 | < Previous Page | 191 192 193 194 195 196 197 198 199 200 201 202  | Next Page >

  • Calculating average (AVG) and grouping by week on large data set takes too long

    - by caioiglesias
    I'm getting average prices by week on 7 million rows, it's taking around 30 seconds to get the job done. This is the simple query: SELECT AVG(price) as price, yearWEEK(FROM_UNIXTIME(timelog)) as week from pricehistory where timelog > $range and product_id = $id GROUP BY week The only week that actually gets data changed and is worth averaging every time is always the last one, so this calculation for the whole period is a waste of resources. I just wanted to know if mysql has a tool to help out on this.

    Read the article

  • wpf how to bind a listbox to a list (two ways) - c#

    - by user429400
    Hi, I want to create a 2 way bind between a listbox and a .NET list. In my GUI, I have a listbox, a textbox and add and remove buttons. The listbox displays cars, and my goal is to create a 2way bind between the .Net car list and the listbox: when the user enters a car into the textbox, it gets updated only in the .Net list, and the listbox is updated automatically. When the user press the GUI "remove" button, a car gets removed from the GUI and the .Net list is updated automatically. I've started to write the xaml code, but figured that I don't actually know how to do the binding on both sides (c# and xaml): <Window x:Class="WpfApplication1.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:c="clr-namespace:WpfApplication1" Title="Window1" Height="300" Width="369" Loaded="Window_Loaded"> <Window.Resources> <ObjectDataProvider x:Key="carsData" ObjectType="{x:Type c:Window1}" /> </Window.Resources> <Grid Width="332"> <ListBox Margin="10,62,0,100" Name="myListBox" HorizontalAlignment="Left" Width="120" ItemsSource="{Binding Source={StaticResource CarsData}}"/> <Button Height="23" Margin="66,0,0,65" Name="addBtn" VerticalAlignment="Bottom" Click="addBtn_Click" HorizontalAlignment="Left" Width="64">add</Button> <TextBox Margin="10,0,0,64.48" Name="myTextBox" Height="23" VerticalAlignment="Bottom" HorizontalAlignment="Left" Width="47" /> <Button Height="23" Margin="66,0,0,33" Name="removeButton" VerticalAlignment="Bottom" HorizontalAlignment="Left" Width="64" Click="removeButton_Click">Remove</Button> </Grid> </Window> There is my c# code: namespace WpfApplication1 { public partial class Window1 : Window { MyModel listMgr; ObservableCollection carList; public Window1() { InitializeComponent(); listMgr = new MyModel(); } private void addBtn_Click(object sender, RoutedEventArgs e) { listMgr.add(new Car(0, myTextBox.Text, 2011)); } private void removeButton_Click(object sender, RoutedEventArgs e) { //myListBox.Items.RemoveAt(0); } private void Window_Loaded(object sender, RoutedEventArgs e) { carList = listMgr.getList(); myListBox.DataContext = carList; //secondListBox.DataContext = carList; } } } Thanks, Li

    Read the article

  • What's the (memory) footprint of a J2EE servlet?

    - by Amr Mostafa
    For Jetty, Tomcat, or any other servlet container of your choice, what's the average footprint (memory, and any other notable resources) of a basic servlet? This includes any other basic objects that you almost always need per servlet, such as a view resolver. I'm not looking for a quantitative number in particular, but any indicative answer that could give an idea of how "heavy" or "lightweight" a servlet is. Thanks in advance

    Read the article

  • Is there a common way to access files, that works both on android and PC?

    - by m01
    Hi, I'm writing an application that will ship in two versions: Android and PC version. Is there a simple way to access files from the shared code? Using java.io is simple, but I don't know how to access android resources or assets using it. And I can't write methods that operate on FileInputStreams instead, because some files contain references to another ones, so I need a way to access them from the method code. Any suggestions?

    Read the article

  • From Java/C++ to XML

    - by Greenhouse Gases
    I know Java and C++ but am looking to get in to XML. I don't want to waste time reading over the basics of programming in a book, so has anyone any recommendations for resources for learning XML that assume a knowledge of programming already, or even better highlight how to switch from Java/C++ to XML ie. main differences etcs.

    Read the article

  • Browser: Randomly Opens Pages in New Windows Without Reason?

    - by Mark R
    This is a very strange thing I've noticed on my computer and past computers over this past year or more. I know when page are meant to open in a new Window and know which settings to use on my browser for this. But on both my browsers Chrome and Firefox, I have this really strange issue. I'm starting to think it's a hacker. When I right click links and select Open Link in New Tab, sometimes they will randomly open in a new window and today it is happening a lot. Like lots and lots. I'm getting really creeped out by it and YES I understand when a link opens in a new window and when it isn't supposed to. And none of these links are meant to open in a new Window. Let me give you an example: I searched Google about my issue and clicked on the result that I thought good. It opened in a new tab but half way through loading in new tab it opens into a new window. Recently, I decided to record my screen and while recording my screen using Camtasia, the issue stops. When I stop recording it starts again, as if it's a human operated issue. VERY strange. This has been going on for months on my old and new computer and on both Firefox and Chrome. Is there something I can do to fix this intermittent problem?

    Read the article

  • SQL and/or LINQ query for determining daily increases in viewers

    - by Gio
    We're montioring usage of a certain resources by monitoring users logins (We can see user logins growing daily). After filtering out repeat inter day logins for users, we'd like to track the # of users using the service each day, and then using that info to determine overall incremental gains for each calendar day. Our table is pretty simple: class ServiceLogin { String login; DateTime loginTime; }

    Read the article

  • Best way to use PHP to run another remote php script.

    - by atwellpub
    Hello, I am wanting to create a web-based cronjob system for my userbase, and would need to know the best way to open a php script on a remote server, and ensure the script runs (could take 3 minutes), and use the least ammount of resources on my own side. There is the possibility of having hundreds of connections open at one time. Any advice on how I should go about doing this? Thanks allot, Hudson

    Read the article

  • Draw to an Image

    - by nXqd
    I'm new to GDI+ and I don't know how to draw to an Image. I've a matrix ( game map ) and tiles, Can I create an Image or a Bitmap, then I draw everything on it, so I can work with it likes an Image I load from resources. Thanks so much :)

    Read the article

  • How can I document and automate a system's configuration?

    - by Diomidis Spinellis
    Having a system's configuration represented by its current state is risky, inefficient, and opaque. At some point you may be left with an unsupported system and no upgrade path. Then configuring a new system compatible with the old is a process or trial and error. Furthermore, if at some point the system is damaged the only option is to go back to the most recent full backup, and try to remember what changes followed from that point. Also, the only way to create a system compatible with the original is through a complete dump/restore. Finally, in such a setup there's no way to know how you solved a particular problem; the only thing you can do is to look at the corresponding configuration files and try to guess what you changed to achieve the desired effect. Currently for each system I maintain, I keep a log file where I record all system administration activity, starting from the installation: installation options, added packages, changes in configuration files, updates, problem fixes etc. In theory this allows me to (manually) replay all changes to arrive at the current state, or to unroll an erroneous change by executing the reverse commands. However, this process is also inefficient, error-prone, and relies on human judgment. Another thing I've tried is to put /etc configuration files under version control with git. This helps me document the changes automatically and also apply them on a clean setup. But it's not without problems: git has to run under sudo, passwords and private keys may be stored in the repository, installed packages can't be meaningfully tracked, and git will have a fit if I try to extend this approach to all the system's directories. I've also thought about performing all changes through shell scripts or makefiles, but I think this process will require a lot of effort and will be fragile. Are there some better methods or tools that I'm missing?

    Read the article

  • Using // in a <script>'s source

    - by Dan Beam
    Hello fellow front-end web h4X0|2s, I was wondering if anyone had any resources, proof, or personal experience in using the age-old http/https JavaScript hack: <script src="//someserver.com/js/script.js"></script> Has anyone encountered issues in any of these browsers (IE 5.5+, FF2+, Chrome, Opera 9+, Safari 3+)? Has anybody had success stories? Thank you for your help.

    Read the article

  • vs2008 resource editor changes rc file language

    - by user346134
    Hi all, I am doing some improvements to an application in vs2008 in c++. When i try to edit resources (for example add an entry in the string table), the vs2008 editor changes the rc file language from LANG_ENGLISH to LANG_NEUTRAL and a non english text is replaced with question marks. If i edit the rc file externally (in notepad), and then load it to the vs2008 it works fine. can anybody help me solve this? thanks Shimon

    Read the article

  • Restricting Edit and Delete

    - by phleet
    I want to be able to edit and delete resources myself, but not allow users of the application to do so. Is there an easy way of doing this in Rails? An incomplete solution would be just to remove the "delete" and "edit" buttons from the index view, but that doesn't disable their ability to do so via direct HTTP requests. Running Rails 2.2.2 and ruby 1.8.7

    Read the article

  • Image from WebView

    - by kostas_menu
    hi!i m getting a photo from the web,but i see it very large..how could i see it with zoom out?this is my code for webView: public class gavros extends Activity { WebView browser; /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.efimerides); browser =(WebView)findViewById(R.id.webview); browser.loadUrl("http://resources.sport-fm.gr/sportfm/newspapers/10/12/24/gavros.jpg"); }}

    Read the article

  • break up recursive function in php

    - by Mike
    What is the best way to break up a recursive function that is using a ton of resources For example: function do_a_lot(){ //a lot of code and processing is done here //it takes a lot of execution time if($true){ //if true we have to do all of that processing again do_a_lot(); } } Is there anyway to make the server only have to take the brunt of the first execution and then break up the recursion into separate processes? Or am I dreaming?

    Read the article

  • Localization of icon and default screen in iPhone

    - by hgpc
    Can the app icon and default screen be localized in iPhone? Has anyone tried it? In theory it should be possible as they're just image resources, but I found no explicit mention of this in the documentation, and I wouldn't like to have my app rejected or failing for this.

    Read the article

< Previous Page | 191 192 193 194 195 196 197 198 199 200 201 202  | Next Page >