If I have an oracle query like below:
SELECT * FROM table_a where A = "1", B = "2", C = "3"
for this query to pickup one of the indexes of table_a...does the index need to be on all 3 of these columns?
What I am asking is:
What if Index is on A, B, C, D?
What if Index is on B, C?
Will the index only be picked when
it is on A, B, C?
I am setting up a dns lookup form using dns_get_record. I set it up to check the A Record and MX Records of the domain that is input. However, I would like it to also display the IP address of the displayed MX Records. Is this possible?
So I have 3 classes.
Abstract class A
Class B extends class A
independent Class C
In class D that contains the main method, I create a list of instances of class B
List<B> b = method-call();` // the method returns a list of instances of class B
Now in class C I have one method that is common to both A and B, and hence I don't want to duplicate it. I want to have one method that takes as input an instance of class A, as follows:
public void some-method(LIst<A> a)
However, when I do:
C c = new C().
c. some-method(b)
I get an error that some-method is not applicable for the argument List, instead it's expecting to get List.
Is there a good way to fix this problem?
Many thanks!
I have the following code, but i`m having error of
Error 6 foreach statement cannot operate on variables of type 'int' because 'int' does not contain a public definition for 'GetEnumerator' C:\Dev\DEV\Code\MvcUI\Models\MappingModel.cs 100 13 MvcUI
How can I solve this?
Note:
string [] projectID;
Class Employee
{
int id {get; set;}
string Name {get;set;}
}
public IEnumerable<SelectListItem> GetStudents()
{
List<SelectListItem> result = new List<SelectListItem>();
foreach (var id in Convert.ToInt32(projectID))
{
foreach( Employee emp in Project.Load(id))
result.Add(new SelectListItem
{
Selected = false,
Text = emp.ID.ToString(),
Value = emp.Name
});
return result.AsEnumerable();
}
}
I have this class:
class A {
private:
int player;
public:
A(int initPlayer = 0);
A(const A&);
A& operator=(const A&);
~A();
void foo() const;
};
and I have function which contains this row:
A *pa1 = new A(a2);
can somebody please explain what exactly is going on, when I call A(a2) compiler calls copy constructor or constructor, thanks in advance
I have one UIButton. I put one image on that. When I click on that image, I get one view.
In that view, there is one UIButton and UIImageview. How can I move this view from Portrait to Landscape mode?
Ok SO, I have a user table and want to define groups of users together. The best solution I have for this is to create three database tables as follows:
UserTable
user_id
user_name
UserGroupLink
group_id
member_id
GroupInfo
group_id
group_name
This method keeps the member and group information separate. This is just my way of thinking. Is there a better way to do this? Also, what is a good naming convention for tables that link two other tables?
I have a DB with user accounts information.
I've scheduled a CRON job which updates the DB with every new user data it fetches from their accounts.
I was thinking that this may cause a problem since all requests are coming from the same IP address and the server may block requests from that IP address.
Is this the case?
If so, how do I avoid being banned? should I be using a proxy?
Thanks
I'm trying to install imageMagick but i've got practically zero server knowledge,
i don't get what this means:
You can easily install Imagemagick on
a cPanel by using cPanel script.
/scripts/installimagemagick will do it
for you.
what is this /scripts business, where do i type it? do i type it? what's this all about?!!!
http://geobaby.in/installing-imagemagick-on-a-cpanel-server/
Hi,
I have 1 UITabelView
I'm giving time to each and every row in cellForRowAtIndexPath: method
but when i'm doing up and down the UITabelView,at that time time overlaps of row from oneanother.
Hi,
is it possible to use date_sub like this ?
$dt = date("Y-m-d h:i:s");
$query = "INSERT INTO `table` (`date`) VALUES ('DATE_SUB('$dt', INTERVAL 15 DAY)')";
$result = MYSQL_QUERY($query);
Thanks
I had inherited this SQL Server where we put data in a table (Call TableA) on a database (DB-A). I can see the tableA in another database on the same server ( DB-B) gets the same data right away.
Any ideas how this is implemented? I am trying to see the trace but so far no luck. Any one has an idea?
At this stage I am not sure if its replication. This is a guess
I am using Eclipse IDE for C/C++ Developers, and i am using the gcc to compile at the moment. How can i change it to compile with a Green Hills compiler? Any help will be appreciated. Thanks!
I have this function:
void ToUpper(char * S)
{
while (*S!=0)
{
*S=(*S >= 'a' && *S <= 'z')?(*S-'a'+'A'):*S;
S++;
}
}
What does it mean for *S != 0, should it be null instead?
Supposed I have the following string:
string str = "<tag>text</tag>";
And I would like to change 'tag' to 'newTag' so the result would be:
"<newTag>text</newTag>"
What is the best way to do it?
I tried to search for <[/]*tag but then I don't know how to keep the optional [/] in my result...
Which is a better way to select ans and quest from the table?
SELECT * FROM tablename WHERE option='ans' OR option='quest'";
OR
SELECT * FROM tablename WHERE option='ans' AND option='quest'";
Thanks so much!
Its been a long time since i've done C++ and I'm running into some trouble with classes referencing eachother.
right now I have something like:
a.h
class a
{
public:
a();
bool skeletonfunc(b temp);
}
====================
b.h
class b
{
public:
b();
bool skeletonfunc(a temp);
}
since each one needs a reference to the other i've found I cant do a #include of eachother at the top or i end up in a weird loop of sorts with the includes.
So how can I make it so that a can use b and vice versa with out making a cyclical #include problem.
thanks!
i want to have a background thread in my app that changes an image every 5 seconds for as long as the app is being run. Can someone point me in the direction of how this works? I am new to threads.
Hello,
In classic MVC the model notifies the view about changes made on it. In C# this means I have to subclass the View I'm interested in and in the subclassed class register to the model's event. For example,
if I were to implement MVC using C# and Winforms, I had to subclass TextBox class and then register inside the MyTextBox's constructor for the model events. Am I correct?
How was this issued in Smalltalk? Does one also need to subclass every View in order to register the model's events, or is there some way to dynamically add events to the views on the fly?
Thanks