Ok, so here's what I've got:
I have a list of elements cached in a variable:
elementList = $(".list-of-elements-with-this-class");
I also have a dynamically generated element from that list cached in another variable:
elementList.click(
function()
{
cachedItem = $(this);
}
);
What I want to do is locate cachedI...
Hi,
In mysql I'd like to do 2 unique LEFT JOINs on the same table cell.
I have two tables.
One table lists individual clients and has a clientNoteID and staffNoteID entry for each client. clientNoteID and staffNoteID are both integer references of a unique noteID for the note store in the notesTable.
clientsTable:
clientID | client...
I want choose all the li in my html that has the <span>Google Map</span> in it and apply
and get the value in href with jquery. I tried going through jquey docs but coulding figure it out. Is this possible?
<li><span>Google Maps Staic Link:</span>
<a target="_blank" href="**Value To Get**" rel="nofollow">Map</a></li>
The actual HTML...
I have a table like this:
id | roll_no | name
---------------------
1 | 111 | Naveed
2 | 222 | Adil
3 | 333 | Ali
If I have data like this:
$fields = array( "id" , "roll_no" ) and $values = array( "1,111", "2,222" );
It means I have to write a sql query to get records from table where (id != 1 and roll_no != 111) an...
Hi there. I have 4 tables:
categories - id, position
subcategories - id, categories_id, position
sub_subcategories - id, subcategories_id, position
product - id, sub_subcategories_id, prod_pos
Now I'm doing tests to find out what's wrong with my query.
So i want to select sub_subcategories, and to get someting like that:
[[1,2,3,4,5...
Hello!
I'm working on a small web application that changes the contents of a select drop-down.
I was wondering if appendChild() and add() both accomplish the same task on a select DOM object in JavaScript?
var someSelect = document.getElementById('select-list');
var newOption = document.createElement('option');
someSelect.appendChild...
SELECT p.id
FROM produkty p, przyporzadkowania pr, stany_magazynowe, gk_grupy_produkty
INNER JOIN sub_subkategorie ssi
ON pr.sub_subkategorie_id = ssi.ID
Tables and their important fields
produkty - id, pozycja
przyporzadkowania - id, produkt_id, sub_kategoria_id, sub_subkategoria_id
sub_subkategorie - id, subkategorie_id, pozycja
sub...
Hi
Do you know if in case as follows there is any way to set sequence of columns? which is first, which one is second etc?
$select->from(array('e' => 'equipment'), array(
'ID_equipment',
'nr_in',
'equipment_type_ID_equipment_type',
'serial_n...
How to get selected text from iframe (working on IE)
...
I'm newbie.
I want to make the client program to receive input from keyboard and data from server. I don't want if while user type something (scanf) and its block to receive data from server.
How to write the code in C ?
Thank you.
...
Select in sqlite where some_colum is empty.
empty counts as both NULL and "".
...
Hi,
I have a select where like query for a seach form which is as follows:
<?php
$bucketsearch = sanitizeone($_POST["bucketsearch"], "plain");
$bucketsearch = strip_word_html($bucketsearch);
?>
if(isset($_POST['search'])){
$result=MYSQL_QUERY( "SELECT * FROM buckets where bucketname like '%$bucketsearch%' order by ...
I have these two tables:
tAccounts
id, name, server_id
tFriends
id_lo, id_hi
Now, I'm trying this query:
SELECT FR.id_lo AS id_friend
FROM tFriends FR, tAccounts AC
WHERE (FR.id_hi = 4 && AC.server_id != -1)
........ In order get the friends of a certain user, while making sure his friend's server_id is different than '-1' !
Any i...
I'm using google translate selects as a reference.
When you click to choose the languages the options shows with multiple columns.
http://translate.google.com/
How can I do that ?
...
In mootools 1.2, getting selected options in a multi select is easy using getSelected:
// code 1
$('my_select').getSelected().each(function(opt) {
// stuff
});
Is there an equivalent of that in mootools 1.1 or do I have to use getChildren() and check whether it has been selected?
What I have at the moment:
// code 2
// get all ...
Hey, guys,
I'm trying to figure out how to select data from a MySQL table based of closeness to a number. Here's what I mean.
I'm writing an application that stores the coordinates of places (longitude and latitude) what I'd like to be able to do is select data from the database based on the location of where the user is. So, say, for ...
Hello, please I have the same problem as I found here
http://stackoverflow.com/questions/409705/mysql-selecting-data-from-multiple-tables-all-with-same-structure-but-different ,
I have to select data from many MySQL tables with identical structure, but different data (split up into table_0, table_1, table_2 etc to table_5 to distribute...
I wrote the following query to obtain a date, remove it's time part and add the time I wanted.
If I run this query without the TOP clause, it works well. But when I add it, it returns the following exception: "Conversion failed when converting date and/or time from character string."
Here is the query:
SELECT TOP 1
CONVERT(DateTime, ...
Hi,
I am trying to display a random product image and description from the access database, so i am selecting the highest idproduct then randomising a number between 1 and %highestid%, this is what i have so far....
IF frontpage = 1 then
SQLSTR = "SELECT idproduct AS prodtot FROM products order by idproduct desc"
Set objRS = Server.C...
I've always preached to my developers that SELECT * is evil and should be avoided like the plague.
Are there any cases where it can be justified?
I'm not talking about COUNT(*) - which most optimizers can figure out.
Edit
I'm talking about production code.
And one great example I saw of this bad practice was a legacy asp application...