I'm using Susbsonic 3 with the LINQ templates. I've already added a column called 'ID' to my Articles table. When I try to insert a row using the following code
var db = new LDB();
int newID = db.Insert.Into<ArticlesTable>
(
x => x.Description
).V...
What is the reason of the error on title? I tested mysql query at Mysql Front and no problem. My script is below. Thank you.
$fbFoodPerma = $fbSiteID."-".$fbFoodPerma;
$sql = mysql_query("
SELECT fbFoodPerma
FROM fbFoods
WHERE fbFoodPerma
LIKE '$fbFoodPerma'") or die(mysql_error());
...
what is the difference between utf8 and latin1?
...
Hello,
Is it available to write a query to use same "LIMIT (from), (count)", but get result in backwards?
In example if I have 8 rows in the table and I want to get 5 rows in two steps I would:
first step query:
select * from table limit 0, 5
first step result:
first 5 rows;
second step query:
select * from table limit 5, 5
se...
Hi,
I have the following tables:
--table sportactivity--
sport_activity_id, home_team_fk, away_team_fk, competition_id_fk, date, time
(tuple example) -> 1, 33, 41, 5, 2010-04-14, 05:40:00
--table teams--
team_id, team_name
(tuple example) -> 1, Algeria
Now I have the following SQL statment that I use to extract Team A vs Team B...
Hi, Which version of MySql.data.dll should I use with NHibernate 2.1.2.4000?? This is also with the latest version of Fluent NH.
Thank you
...
I have two tables, Table A with 700,000 entries and Table B with 600,000 entries. The structure is as follows:
Table A:
+-----------+---------------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+-----------+---------------------+------+-----+---------+-------...
As a beginning web developer, I try my best to clean up all the user inputs through checks and what not. However, today, I found out my website was hacked (I'll share their website on request) and it really made my wonder how did they do it. I'm in the process of getting my website back together. What should I do to prevent these things?...
Hi,
after extensive trawling of the internet I still havent found any solution for this problem.
I`m writing a small C++ app that connects to an online database and outputs the data in a listbox.
I need to enable a search function using an edit box, but I cant get the query to work while using a variable.
My code is:
res = mysql_perf...
I have 3 MySQL tables.
companies with company_id and company_name
products with product_id and company_id
names with product_id, product_name and other info about the product
I'm trying to output the product_name and the company_name in one query for a given product_id.
Basically I need information from the names and companies table...
I've been googling around for a really simple way of making what is, in effect, nothing more than an enhanced phpMySql.
In a mysql database, I have:
Name, address, phone, website etc, plus 2 or 3 custom fields. This data is pulled out to make a website.
All I want is to be able to make a freeform form, a bit like Access, but for the w...
What's the best way to run a query so that spaces in the fields are
ignored? For example the following queries....
SELECT * FROM mytable WHERE username = "JohnBobJones"
SELECT * FROM mytable WHERE username = "John Bob Jones"
.
would find the following entries:
John Bob Jones
JohnBob Jones
JohnBobJones
.
I am using php or python...
Hi All,
I am making a database of my client's customers to send email promotions to. The database will include all about 12 of my clients and each of them has an average of 2100 customers. I was wondering if it would be better to have a table in the db for each one of my clients that contains a list of their customers or if I should jus...
Hi,
How do I write the following MySQL query using Doctrine's findBy*() method?:
SELECT column_name1, column_name2 FROM table_name
WHERE column_name3 LIKE '%search_key%';
For Example, to fetch multiple rows from a column named "ColumnName" (below) using Doctrine:
$users = Doctrine::getTable('User')->findByColumnName('active');
echo...
I'm basically a front end designer and new to PHP and MySQL but I want a user to be able to store multiple names and there meanings in a MySQL database table named names using PHP I will dynamically create form fields with JQuery every time a user clicks on a link so a user can enter 1 to 1,000,000 different names and there meanings whic...
Hi,
This is my first time building a website and using CodeIgniter for a school project. I was wondering whether you have any tips on uploading CI to a free web host , my database, free webhosting and basic security tips.
Can I just upload the entire CI folder? Or do I have to upload individual files (God no!)? What are my options?
Wh...
Is there a way to create a dump/export/save a temporary MySQL table into a file on disk(.sql file that is, similar to one that is created by mysqldump)?
...
$sql = "SELECT * FROM news ORDER BY `news_id` DESC LIMIT 1";
$result = mysql_query($sql) or die(mysql_error());
$row = mysql_fetch_assoc($result);
$date = $row['time_posted'];
echo "<i> " .date("Y/m/d", $date) . "</i>: ";
I used timestamp in mysql. So, what's the problem?
...
I have two .php files which show all contacts in a database, then allows the user to choose a contact to be edited.
The first script is called pick_modcontact.php where I choose a contact, then posts to the script show_modcontact.php When I click the post button on the form on pick.modcontact.php the browser returns to that file due to ...
I'm a database newbie designing a database. I'll use SO as an example because it's easier to ask it on something that you can see already, but it's not the same, it will just help me understand the right approach.
As you can see, there are many questions here and each can have many answers.
How should I store the answers in a table?
S...