MySQL Questions


Multiple foreign keys?

I've got a table that is supposed to track days and costs for shipping product from one vendor to another. we (brilliantly :p) stored both the

mysql full text search is empty

I am using ruby on rails with a mysql backend. i have a table called notes and here is the migration i use to create it: def

MySQL Results to a File

How do i write the results from a mysql query to file? i just need something quick. output can be csv, xml, html, etc.

Generate field in MySQL SELECT

If i've got a table containing field1 and field2 can i generate a new field in the select statement? for example, a normal query would be:

Add 1 to a field

How do i turn the following 2 queries into 1 query $sql = "select level from skills where id = $id limit 1;"; $result =

Nested dropdown

I'm building a form with php/mysql. i've got a table with a list of locations and sublocations. each sublocation has a parent location. a column

Notice: Undefined index: myfile

Iam trying to build an upload form and iam getting notices ( ! ) notice: undefined index: myfile in c:\wamp32\www\game\upload.php on line 19 and

How-to: Ranking Search Results

I have a webapp development problem that i've developed one solution for, but am trying to find other ideas that might get around some performance

Truncate Slow Query Log in MySQL

What's the safest way to truncate the mysql slow query log (under linux primarily, but windows would be handy to know) while mysql is running?

Finding the Latest Post by Author

I'm building an "authors" page for my wordpress blog that lists all the current site contributors along with various other information such as

Multi user role in laravel 8

I want to redirect to the user's dashboard according to role. i have created a separate table for the user role and a separate table for the user.

Laravel using WHERE orWHERE

I have a query as below. when i search using the query below, it fetches the products but it shows other products from other airlines even tho i

php--guestbook pager

I am a new learner of php, now i want to write a simple guestbook. but i don't know how to write the pager's part. any one can instruct me? or

Blog Categories