Search Results

Search found 9462 results on 379 pages for 'three tier'.

Page 12/379 | < Previous Page | 8 9 10 11 12 13 14 15 16 17 18 19  | Next Page >

  • Echo items with value of three

    - by user342391
    I need to echo all items in my row that have the value of three. If a field has the value of three I then need to echo the 'name' and 'description' on that row. This is what I have so far $result = mysql_query($query1) or die(mysql_error()); while ($row = mysql_fetch_array($result)) { echo $row['status']; } I need to write 'if $row[`status´ == 3 echo 'description' 'name' else echo 'no current staus' I hope I made some sense because I am seriously confused

    Read the article

  • How to get JOptionPane with three text fields

    - by Dr.Mostafa
    I want to know how i can do a messageBox from three input dialog .. Like this: JOptionPane.showInputMessageDialog("Enter your FirstName"); JOptionPane.showInputMessageDialog("Enter your MiddleName"); JOptionPane.showInputMessageDialog("Enter your LastName"); But I want one message has a three input boxes.

    Read the article

  • iPhone - Track three touches

    - by Striker
    Suppose you have three points of contact on the iPhone screen and one of those touches moves... The touchesMoved method will be invoked and the [[event touchesForView:self] count] will be equal to '3' because there are three touches for the event, but how can you distinguish between the touches? For example - find out whether it was the first, second, or third touch which moved? Thanks.

    Read the article

  • Three-way full outer join in SQLite

    - by Vince
    I have three tables with a common key field, and I need to join them on this key. Given SQLite doesn't have full outer or right joins, I've used the full outer join without right join technique on Wikipedia with much success. But I'm curious, how would one use this technique to join three tables by a common key? What are the efficiency impacts of this (the current query takes about ten minutes)? Thanks!

    Read the article

  • Three 1D Arrays to One 2D Array

    - by Steven
    I have a function which accepts a 2D array, but my data is in three 1D arrays. How do I create a 2D array consisting of the three arrays to pass to the subroutine? Dim Y0(32) As Double Dim Y1(32) As Double Dim Y2(32) As Double 'Code to fill arrays' 'Attempting to call:' Sub PlotYMult(YData(,) as Double)

    Read the article

  • SQL query to select records from three Tables seperatly

    - by Azhar
    SQL query which select the record from three tables and there is no relation between these tables. Actually I want to make it a VIEW. suppose there are three tales Table1, Table2, Table3 I want to show records of Table1 first with some filter criteria and then the records from Table2 and in last from Table3 as when we execute the view it show like the records like a Table. There can be any number of rows but the records must be in this sequence.

    Read the article

  • Multi-tier applications using L2S, WCF and Base Class

    - by Gena Verdel
    Hi all. One day I decided to build this nice multi-tier application using L2S and WCF. The simplified model is : DataBase-L2S-Wrapper(DTO)-Client Application. The communication between Client and Database is achieved by using Data Transfer Objects which contain entity objects as their properties. abstract public class BaseObject { public virtual IccSystem.iccObjectTypes ObjectICC_Type { get { return IccSystem.iccObjectTypes.unknownType; } } [global::System.Data.Linq.Mapping.ColumnAttribute(Storage = "_ID", AutoSync = AutoSync.OnInsert, DbType = "BigInt NOT NULL IDENTITY", IsPrimaryKey = true, IsDbGenerated = true)] [global::System.Runtime.Serialization.DataMemberAttribute(Order = 1)] public virtual long ID { //get; //set; get { return _ID; } set { _ID = value; } } } [DataContract] public class BaseObjectWrapper<T> where T : BaseObject { #region Fields private T _DBObject; #endregion #region Properties [DataMember] public T Entity { get { return _DBObject; } set { _DBObject = value; } } #endregion } Pretty simple, isn't it?. Here's the catch. Each one of the mapped classes contains ID property itself so I decided to override it like this [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.Divisions")] [global::System.Runtime.Serialization.DataContractAttribute()] public partial class Division : INotifyPropertyChanging, INotifyPropertyChanged { [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ID", AutoSync=AutoSync.OnInsert, DbType="BigInt NOT NULL IDENTITY", IsPrimaryKey=true, IsDbGenerated=true)] [global::System.Runtime.Serialization.DataMemberAttribute(Order=1)] public override long ID { get { return this._ID; } set { if ((this._ID != value)) { this.OnIDChanging(value); this.SendPropertyChanging(); this._ID = value; this.SendPropertyChanged("ID"); this.OnIDChanged(); } } } } Wrapper for division is pretty straightforward as well: public class DivisionWrapper : BaseObjectWrapper<Division> { } It worked pretty well as long as I kept ID values at mapped class and its BaseObject class the same(that's not very good approach, I know, but still) but then this happened: private CentralDC _dc; public bool UpdateDivision(ref DivisionWrapper division) { DivisionWrapper tempWrapper = division; if (division.Entity == null) { return false; } try { Table<Division> table = _dc.Divisions; var q = table.Where(o => o.ID == tempWrapper.Entity.ID); if (q.Count() == 0) { division.Entity._errorMessage = "Unable to locate entity with id " + division.Entity.ID.ToString(); return false; } var realEntity = q.First(); realEntity = division.Entity; _dc.SubmitChanges(); return true; } catch (Exception ex) { division.Entity._errorMessage = ex.Message; return false; } } When trying to enumerate over the in-memory query the following exception occurred: Class member BaseObject.ID is unmapped. Although I'm stating the type and overriding the ID property L2S fails to work. Any suggestions?

    Read the article

  • Targeting specific material by name in the imported model

    - by Aleksander Lenart
    I'm trying to select a particular material in the imported model (via Collada loader) in Three.js. I know this can be done with the getChildByName method but it just doesn't work for me. I couldn't find any working example with this method included, either. What am I doing wrong here? loader = new THREE.ColladaLoader(); loader.load('myModel.dae', function ( collada ) { model = collada.scene; var myMaterial = model.getChildByName( 'materialName', true ); myMaterial.material = new THREE.MeshBasicMaterial( { wireframe: true } ); });

    Read the article

  • Question about how to use strong typed dataset in N-tier application for .NET

    - by sb
    Hello All, I need some expert advice on strong typed data sets in ADO.NET that are generated by the Visual Studio. Here are the details. Thank you in advance. I want to write a N-tier application where Presentation layer is in C#/windows forms, Business Layer is a Web service and Data Access Layer is SQL db. So, I used Visual Studio 2005 for this and created 3 projects in a solution. project 1 is the Data access layer. In this I have used visual studio data set generator to create a strong typed data set and table adapter (to test I created this on the customers table in northwind). The data set is called NorthWindDataSet and the table inside is CustomersTable. project 2 has the web service which exposes only 1 method which is GetCustomersDataSet. This uses the project1 library's table adapter to fill the data set and return it to the caller. To be able to use the NorthWindDataSet and table adapter, I added a reference to the project 1. project 3 is a win forms app and this uses the web service as a reference and calls that service to get the data set. In the process of building this application, in the PL, I added a reference to the DataSet generated above in the project 1 and in form's load I call the web service and assign the received DataSet from the web service to this dataset. But I get the error: "Cannot implicitly convert type 'PL.WebServiceLayerReference.NorthwindDataSet' to 'BL.NorthwindDataSet' e:\My Documents\Visual Studio 2008\Projects\DataSetWebServiceExample\PL\Form1.cs". Both the data sets are same but because I added references from different locations, I am getting the above error I think. So, what I did was I added a reference to project 1 (which defines the data set) to project 3 (the UI) and used the web service to get the DataSet and assing to the right type, now when the project 3 (which has the web form) runs, I get the below runtime exception. "System.InvalidOperationException: There is an error in XML document (1, 5058). --- System.Xml.Schema.XmlSchemaException: Multiple definition of element 'http://tempuri.org/NorthwindDataSet.xsd:Customers' causes the content model to become ambiguous. A content model must be formed such that during validation of an element information item sequence, the particle contained directly, indirectly or implicitly therein with which to attempt to validate each item in the sequence in turn can be uniquely determined without examining the content or attributes of that item, and without any information about the items in the remainder of the sequence." I think this might be because of some cross referenceing errors. My question is, is there a way to use the visual studio generated DataSets in such a way that I can use the same DataSet in all layers (for reuse) but separate the Table Adapter logic to the Data Access Layer so that the front end is abstracted from all this by the web service? If I have hand write the code I loose the goodness the data set generator gives and also if there are columns added later I need to add it by hand etc so I want to use the visual studio wizard as much as possible. thanks for any help on this. sb

    Read the article

  • Connect three computers (including one laptop) to one monitor

    - by Jesse Beder
    I have the following hardware: 2 Desktop PCs, running Windows XP and Ubuntu Macbook Pro a LCD monitor, a wired keyboard, and a wired mouse Currently, I'm using an oldish IOGear KVM switch to connect the two PCs to the input/output (and it works very well). I'd like a setup that includes the laptop as well, ideally maintaining as much portability as possible (meaning I'd like to be able to sit down, easily plug in my laptop, work on all computers, then easily pick up and leave with the laptop - is docking station the right word here?). What hardware do I need to do this?

    Read the article

  • Why do I have three My Documents folders?

    - by root45
    I'm trying to fix my profile on Windows 7. Currently %USERPROFILE% points to C:\Users\myUsername My Documents is also at C:\Users\myUsername \\profileServer\profiles$\myUsername has TWO "My Documents" folders Neither of these folders contain what's in C:\Users\myUsername\My Documents Navigating to %USERPROFILE% in Windows Explorer displays two copies of everything, one local and one copy from the server. Programs use sort of a toss up between C:\Users\myUsername\My Documents or one of the two My Documents on profileServer. According to our sysadmins, My Documents is supposed to point to the profile server, but other folders should be local. How can I fix this so I have ONE copy of everything, with My Documents pointing to \\profileServer\profiles$\myUsername\Documents and everything else local? To be honest, I don't understand why this is so difficult and confusing. For example, why does Windows allow displaying two folders with the same name in the same directory? And why does inputting C:\Users\myUsername and %USERPROFILE% into Windows Explorer produce two different results? They should be identical. Some screenshots My directory on the profileServer My local user directory, C:\Users\myUsername Navigating to %USERPROFILE% in Windows Explorer Showing that %USERPROFILE% is set to a local directory

    Read the article

  • having trouble setting up ganglia on three machines

    - by Pieter Breed
    I am running ubuntu 11.10 I have one machine with gmetad, gmond and ganglia-webinterface. When I browse the web interface this machine picks up the local gmond output. I then added another machine, running only gmond. I didn't really change anything in the config, only the name of the cluster. This machine's output showed up in the web view. The I tried to add a third machine, similarly to the second, but it's not showing up in the web view. I tried looking at syslog and running as a daemon, but I'm not seeing anything suspicious there. Any tips for trouble shooting this?

    Read the article

  • Windows 7: from Geforce 8800 to three monitors?

    - by lance
    I've got a GeForce 8800 that I've quite happy with. It drives my two 23" widescreen displays well. Now I've got a 19" standard display that I want to stick between the two widescreens. My second PCIe 16x slot is unused (as is the PCI slot below that), and I want to add a card to my Win7 x64 system. This 19" display won't be used for gaming, so I don't need anything fancy. Here are two cards I was considering, but I'm wondering if they're bad choices for some reason? If they're both fine choices, which is better and why? Again, I'm needing to power only the 19" standard display with this card, and it won't play games. I just need 1280x1024 in Win7 x64. NVidia: Galaxy 95TFE8HUFEXX GeForce 9500 GT Video Card - 512MB DDR2, PCI Express 2.0 ATI: ASUS EAH4350 SILENT/DI/51 Radeon HD 4350 Video Card - 512MB DDR2, PCI Express 2.0

    Read the article

  • Amazon EC2 Instance - m1.medium Ubuntu 12.04 - Started to crash three days ago

    - by Joy
    The environment: Amazon EC2 Instance - m1.medium Ubuntu 12.04 Apache 2.2.22 - Running a Drupal Site Using MySQL DB Server RAM info: ~$ free -gt total used free shared buffers cached Mem: 3 1 2 0 0 0 -/+ buffers/cache: 0 2 Swap: 0 0 0 Total: 3 1 2 Hard drive info: Filesystem Size Used Avail Use% Mounted on /dev/xvda1 7.9G 4.7G 2.9G 62% / udev 1.9G 8.0K 1.9G 1% /dev tmpfs 751M 180K 750M 1% /run none 5.0M 0 5.0M 0% /run/lock none 1.9G 0 1.9G 0% /run/shm /dev/xvdb 394G 199M 374G 1% /mnt The problem About two days ago the site started failing becaue the MySQL server was shut down by Apache with the following message: kernel: [2963685.664359] [31716] 106 31716 226946 22748 0 0 0 mysqld kernel: [2963685.664730] Out of memory: Kill process 31716 (mysqld) score 23 or sacrifice child kernel: [2963685.664764] Killed process 31716 (mysqld) total-vm:907784kB, anon-rss:90992kB, file-rss:0kB kernel: [2963686.153608] init: mysql main process (31716) killed by KILL signal kernel: [2963686.169294] init: mysql main process ended, respawning That states that the VM was occupying 0.9GB, but my Ram has 2GB free, so 1GB was still left free. I understand that in Linux applications can allocate more memory than physically available. I don't know if this is the problme, it's the first time that it has started to happen. Obviously, the MySQL server tries to restart, but there's no memory for it apparently and it won't restart. Here is its error log: Plugin 'FEDERATED' is disabled. The InnoDB memory heap is disabled Mutexes and rw_locks use GCC atomic builtins Compressed tables use zlib 1.2.3.4 Initializing buffer pool, size = 128.0M InnoDB: mmap(137363456 bytes) failed; errno 12 Completed initialization of buffer pool Fatal error: cannot allocate memory for the buffer pool Plugin 'InnoDB' init function returned error. Plugin 'InnoDB' registration as a STORAGE ENGINE failed. Unknown/unsupported storage engine: InnoDB [ERROR] Aborting [Note] /usr/sbin/mysqld: Shutdown complete I simply restarted the Mysql service. About two hours later it happened again. I restarted it. Then it happened again 9 hours later. So then I thought of the MaxClients parameter of apache.conf, so I went to check it out. It was set at 150. I decided to drop it down to 60. As so: <IfModule mpm_prefork_module> ... MaxClients 60 </IfModule> <IfModule mpm_worker_module> ... MaxClients 60 </IfModule> <IfModule mpm_event_module> ... MaxClients 60 </IfModule> Once I did that, I had the apache2 service restart and it all went smoothly for 3/4 of a day. Since at night the MySQL service shut down once again, but this time it wasn't killed by the Apache2 service. Instead it called the OOM-Killer with the following message: kernel: [3104680.005312] mysqld invoked oom-killer: gfp_mask=0x201da, order=0, oom_adj=0, oom_score_adj=0 kernel: [3104680.005351] [<ffffffff81119795>] oom_kill_process+0x85/0xb0 kernel: [3104680.548860] init: mysql main process (30821) killed by KILL signal Now I'm out of ideas. Some articles state that the ideal thing to do is change the kernel behaviour with the following (include it to the file /etc/sysctl.conf ) vm.overcommit_memory = 2 vm.overcommit_ratio = 80 So no overcommits will take place. I'm wondering if this is the way to go? Keep in mind I'm no server administrator, I have basic knowldege. Thanks a bunch in advance.

    Read the article

  • three monitors with radeon 5870 on 1920x 1080

    - by antoniocs
    Hey! I have 3 monitors, 2 24 inch and one 22 inch. The max resolution of the 24 inch monitors is 1920 x 1080 and the 22 is a bit less (can't remember right now). I read Jeff's post about the display port adapters and I was wondering if passive adapter would do the trick since neither of the monitors have big resolutions. Thanks

    Read the article

  • WPF & RenderTierCapability, what could cause a machine to be dropped from Tier 2 to 0?

    - by Erode
    I'm having an issue on some imaged machines where they will started out on Tier 2 and after some time of use (they are well spec'd kiosk machines, quad-core, Nvidia 550Ti), they drop to Tier 0 and effectively become useless. Restarting the machine doesn't seem to help. This is a problem more than just "missing hardware acceleration" because my application requires D3DImage to function (which requires Tier 2). Thanks for any help!

    Read the article

  • Mixing both local and nonlocal addresses on three switches

    - by klew
    I have four computers that have nonlocal addresses like 150.X.X.X. Now I also get another few computers that should be only accessible through a gateway (it will be computing cluster) and they addresses are 10.0.0.X. I also wanted to include those four older computers to this new cluster, but I want them to be accessible from internet on nonlocal addresses (so I would like to set up them on both 150.X.X.X and 10.0.0.X addresses - I've set up it as interface eth0:0 since I have only one NIC). Those new computers have their switch and old computers also have their own switch. Both of them are connected to another (third) switch. The problem is that those old computers see each other (I can ping them), and also new computers see each other, but I can't ping old computer from new computer and vice versa. However pinging on nonlocal adresses works as expected. I looked into switch configuration and didn't find anything useful. I have no idea what I missed here. Can somebody help? All computers have Ubuntu Server 10.04

    Read the article

  • How to make one CPU to be used simulataneously be three different users

    - by beginning_steps
    As a bootstrapping start-up we are thinking of saving on the IT hardware cost by making more use of the hardware that we have. As a solopreneur I have a laptop config : intel core2duo processor, 3Gb RAM and 250 GB RAM. Now we are planning to increase our team to 3 members. Will like your suggestions on the nest cost-effective step that I can take so that I can use the computing power of the existing laptop to act as a kind of server and then buy to more monitors where the new recruits can do the daily work on and they need to have different login id and access and they dont need access to all the files/applications as are available in my laptop. We use internet intensively to do our day to day activity. Please share you experience, whether you think this is a good ploy or there is any other more effective way of achieving the same result.

    Read the article

  • Blending Three Images into Graphics Context Using Alpha Blend Mode kBlendModeOverlay

    - by steganous
    Does kCGBlendModeOverlay not work exactly like Photoshop's Overlay blending mode? I'm trying to overlay three images into a graphic context via: [uiimageGreen drawAtPoint:CGPointMake(x, y) blendMode:kCGBlendModeOverlay alpha:1.0]; [uiimageRed drawAtPoint:CGPointMake(x, y) blendMode:kCGBlendModeOverlay alpha:1.0]; [uiimageBlue drawAtPoint:CGPointMake(x, y) blendMode:kCGBlendModeOverlay alpha:1.0]; In the end, if I overlay just two of the three, the result is much closer to my desired output color in places where both images intersect. Adding the third image, however, causes the first-drawn image's color to be dominant in the resulting mix of colors. (e.g. in the above code, green comes out dominant, when the result should actually be white) Do you get the same result if you try?

    Read the article

  • Three vertically stacked DIVs with scrolling middle

    - by Dave
    Is it possible to stack three DIVs vertically and have just the middle div scroll vertically? I don't want to use pixel heights, though, because the DIVs are inside of a dialog box that is resizeable. Something like this (pardon my lousy ASCII art): +-----------+ | Header | +-----------+ | ^| | || | Scroll || | || | v| +-----------+ | Footer | +-----------+ The goal is to have the header and and footer fixed and, as the dialog grows, the middle div would grow vertically. Maybe I'm just being stupid, but I've been fighting this for the last few hours and can't seem to get it right. The three DIVs probably need to be inside "another" DIV but when I do that, and set the height to 100%, it grows as the middle DIV grows. Again, it's probably something silly I'm not accounting for. I've also tried using a TABLE to no avail. Thanks for any help.

    Read the article

  • Unique keys for Sphinx along three vectors instead of two

    - by Brendon Muir
    I'm trying to implement thinking-sphinx across multiple 'sites' hosted under a single rails application. I'm working with the developer of thinking-sphinx to sort through the finer details and am making good progress, but I need help with a maths problem: Usually the formula for making a unique ID in a thinking-sphinx search index is to take the id, multiply it by the total number of models that are searchable, and add the number of the currently indexed model: id * total_models + current_model This works well, but now I also through an entity_id into the mix, so there are three vextors for making this ID unique. Could someone help me figure out the equation to gaurantee that the id's will never collide using these three variables: id, total_models, total_entities The entity ID is an integer. I thought of: id * (total_models + total_entities) + (current_model + current_entity) but that results in collisions. Any help would be greatly appreciated :)

    Read the article

  • How to program three editions Light, Pro, Ultimate in one solution

    - by Henry99
    I'd like to know how best to program three different editions of my C# ASP.NET 3.5 application in VS2008 Professional (which includes a web deployment project). I have a Light, Pro and Ultimate edition (or version) of my application. At the moment I've put all in one solution with three build versions in configuration manager and I use preprocessor directives all over the code (there are around 20 such constructs in some ten thousand lines of code, so it's overseeable): #if light //light code #endif #if pro //pro code #endif //etc... I've read in stackoverflow for hours and thought to encounter how e.g. Microsoft does this with its different Windows editions, but did not find what I expected. Somewhere there is a heavy discussion about if preprocessor directives are evil. What I like with those #if-directives is: the side-by-side code of differences, so I will understand the code for the different editions after six months and the special benefit to NOT give out compiled code of other versions to the customer. OK, long explication, repeated question: What's the best way to go?

    Read the article

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