multiple

MySQL - Selecting data from multiple tables all with same structure but different data

Ok, here is my dilemma I have a database set up with about 5 tables all with the exact same data structure. The data is separated in this manner for localization purposes and to split up a total of about 4.5 million records. A majority of the time only one table is needed and all is well. However, sometimes data is needed from 2 or more...

RESTful way to create multiple items in one request

I am working on a small client server program to collect orders. I want to do this in a "REST(ful) way". What I want to do is: Collect all orderlines (product and quantity) and send the complete order to the server At the moment I see two options to do this: Send each orderline to the server: POST qty and product_id I actually don...

Is there any library to query the whois database for domains information?

Hi, I'd like to write my own script in C# to test my own dictionary of too-many-to-do-it-manually words against whois database of world wide web domains. Is there any free library / script that would allow my application to test the words against free domains and get the results quite quick? There are Internet applications like whoix...

Multiple submit buttons/forms in Rails

I am trying to write a rails application which lets you go to a certain page, say /person/:id. On this page it shows a set of available resources. I want each resource to have a button next to it, which reserves that resource to that person (by creating a new instance of an Allocation model.) As an extension, I'd like several buttons by ...

Take multiples matches with regex separated by defined marks

Hello. I have a text and I need to take the content in a defined pattern. A content between MARK1 and MARK2 and content after MARK2. However, those marks can repeat and I need to take all their ocurrences. In the example below: text: "textA textB _MARK1_ textC _MARK2_ textD _MARK1_ textE textF _MARK2_ textG textH textI" array(0): _MARK...

linking multiple files kernel module programming

I am just writing a test file and then i am trying to call a function inside my kernel. Can somebody tell if i am making a mistake in my makefile or my code?? I wanted to call my int d = add(2, 4); function but the program does not seem to link test.c file with sourceadd2.c. /* sourceadd2.c */ define KERNEL define MODULE include "t...

Multipe keys in Access?

Years ago, I created a data base in MS Excel to keep track of my photographs. The way I designed it was as follows. I had a master sheet that had a primary key with a sequenctial number ID for every photo. Then I had several sheets in the workbook that contained specific photos of the same subject, e.g. landscapes (LS), seascapes (SC)...

ASP.NET app MSI installer multiple instances

I want to be able to produce a single MSI from VS08 which can be used to install e.g. demo, staging and production versions of the same app on the same website in the same IIS. In other words, the user needs to be in control of how many instances they want - I'm not in a position to pre-generate them by varying the product code (though ...

How to select multiple records (row) from a column in mysql?

I want to display four (4) items'name from these id: Can I do like this? SELECT item_name from items WHERE item_id IN ('001', '012', '103', '500') or SELECT item_name from items WHERE item_id = '001' or item_id = '012' or item_id = '103' or item_id = '500' IN RESPONSE TO ALL ANSWERS Well, most of the answers said it works, but it do...

Select distinct from multiple fields using sql

I have 5 columns corresponding to answers in a trivia game database - right, wrong1, wrong2, wrong3, wrong4 I want to return all possible answers without duplicates. I was hoping to accomplish this without using a temp table. Is it possible to use something similar to this?: select c1, c2, count(*) from t group by c1, c2 But this re...

Aggregation with two Joins (MySQL)

Hi! I have one table called gallery. For each row in gallery there are several rows in the table picture. One picture belongs to one gallery. Then there is the table vote. There each row is an upvote or a downvote for a certain gallery. Here is the (simplified) structure: gallery ( gallery_id ) picture ( picture_id, picture_gallery_re...

CSS Form styling with multiple controls on one line

I want to make a CSS form with multiple textbox/label combinations on a single line. Most examples I see show each line getting a separate form field. For example, I'd like Last Name and First Name textboxes on one line and Phone Number on a second line. ...

Best way to handle multiple constructors in Java

Hey, I've been wondering what the best (i.e. cleanest/safest/most efficient) way of handling multiple constructors in Java is? Especially when in one or more constructors not all fields are specified: public class Book { private String title; private String isbn; public Book() { //nothing specified! } p...

"multiple types in one declaration" but no ; missing.

I tried to compile my program, with Code::Blocks (gcc compiler). And I get an error: Here is the source file it complaining about: #ifndef BOT_H #define BOT_H #include "player.h" #include "timer.h" class BOTS; // forward decalaration of BOTS class BOT : public PLAYER { public: enum BotStatus{BotMoving,BotPursue,BotChasePowerup}; ...

Returning anonymous types from stored procedure with LINQ2SQL

Consider the following stored procedure: SELECT * FROM Customers; SELECT Customer.Id, Customer.Name, Order.Total, Order.DateOrdered FROM Customers INNER JOIN Orders ON Customers.Id = Orders.CustomerId; The procedure obviously returns two result sets which I'm trying to retrieve with this partial class method: public partial class DB...

More Primary / Auto-adding unique IDs per one table in MySQL?

Hi, Is it possible to have two and more primary/automatic-adding unique IDs per one table in MySQL? For example: Primary Key (INT,11);shop_id;invoice_id 1;200;2001 1;201;2011 2;200;2002 2;201;2012 Is it possible to set this to MySQL table ? -> So there are more primary keys for some other value in the table.. ? I am looking for mor...

Passing several parameters as a single parameter in Java.

I've seen an example of it before, but I've never really found any good reference material dealing with it. I know it's possible to pass in several parameters, ints for example, by defining the method as public void aMethod(int...a) But I don't know any more about it than that. I've seen an example, and it returned the average of ...

Selecting items in a listbox using C#

Hi, I am using two listbox controls in my wpf window that are identical (identical = itemsource of both the listbox is same and so they look same) and the selection mode on both the listboxes is set to Multiple. Lets call the listboxes LB1 and LB2 for the time being, now when I click an item in LB1, I want the same item in LB2 to get se...

How to create an SQL Server 2005 CTE to return parent-child records, for children with multiple parents.

Hi there. I'm experimenting with CTE's in SQL Server but have reached a dead end with getting the following scenario to work. I have a hierarchy table similar to this: Node(ID:439) Node(ID:123) Node(ID:900) Node(ID:56) Node(ID:900) Expected results: NodeID ParentNodeID 439 0 123 439 900 123 56 439 90...

Let Apache serve multiple directories through single <Location>

OK. I'm pretty much an apache HTTPD noob so please bare with me. I have an issue with serving a large amount of VirtualHosts and I was wondering if there is a more efficient way of doing things. I'm currently using the Location directive to serve a large amount projects from different departments, over 300 projects from 19 departments ...